Language: ChineseGermanSpanishFrenchDutchItalianRussian
123 Flash Chat Forums

Go Back   TOPCMM Community > SWFKit > SWFKit Support

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-17-2007, 06:16 PM
Member
 
Join Date: May 2007
Posts: 53
Default Problem with Application.Interaction.lBtnClk

Why, when i set Application.Interaction.lBtnClk = $LBDRAG; my movie continues to receive mouse events? And if interactive element was clicked, no drug is available?
__________________
#define true false //happy debugging, friends
Reply With Quote
  #2 (permalink)  
Old 05-18-2007, 09:41 AM
Member
 
Join Date: May 2007
Posts: 53
Default Re:Problem with Application.Interaction.lBtnClk

Is my problem unsolvable? Its quite critical.
__________________
#define true false //happy debugging, friends
Reply With Quote
  #3 (permalink)  
Old 05-18-2007, 11:24 AM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Problem with Application.Interaction.lBtnClk

It should not be a problem. To block mouse events, you would have to set lBtnClk to $LBIGNORE. And you cannot drag the main window when the mouse pointer is in an interactive item, such as a text field, because the drag action in that items have special uses. For example, the drag action in a text field means to select words.
Reply With Quote
  #4 (permalink)  
Old 05-21-2007, 08:01 AM
Member
 
Join Date: May 2007
Posts: 53
Default Re:Problem with Application.Interaction.lBtnClk

It is allclear. But sometimes i need to use all the app's square for dragging.
For example. I use multi-windowed app (in one form), and i want windows in background to be dragable, not clickable. So i put a MC in front of them with
Code:
mc.onRelease = function() {}; mc.useHandCursor = false;
to block window's onRelease_handlers.
For sure, i can use a bitmap-copy of BG-windows, but it will make my app to slow down a little bit.
In Zinc, by the way, i can fully block sending mouse events to flash, and then, send it with sendMessageA (winAPI func). But in SWKit this trick doesn't work :-(
Code:
import flash.external.ExternalInterface;
import SWFKit.Global;
_root.onMouseDown = function() {
_root['aaa'].text = 'Clicked! '+Math.random();
};
_root.onEnterFrame = function() {
ExternalInterface.call('sendLBDown', 100, 100);
};
Code:
dllimport "user32.dll" stdcall int SendMessageA(pointer, long, long, long) as user32_SendMessage;
function sendLBDown(x, y) {
var a = user32_SendMessage(winID, 0x0201, 0x0001, x + y*256*256);
trace(a);
}
__________________
#define true false //happy debugging, friends
Reply With Quote
  #5 (permalink)  
Old 05-21-2007, 01:16 PM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Problem with Application.Interaction.lBtnClk

In swfkit, if the mouse events are blocked, the SendMessage api does not work, for the events it sends will also be blocked. Could you please send us a sample of your app? We will try to find a solution.
Reply With Quote
  #6 (permalink)  
Old 05-21-2007, 06:33 PM
Member
 
Join Date: May 2007
Posts: 53
Default Re:Problem with Application.Interaction.lBtnClk

www.100mbit.ru/_tmp/sample.rar
This is a sample app. To see my problem one needs to create a new SWFKit app, paste a Initialize script from archive and link fla-file with SWFKit project.

Thanks in advance.
__________________
#define true false //happy debugging, friends
Reply With Quote
  #7 (permalink)  
Old 05-22-2007, 10:33 AM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Problem with Application.Interaction.lBtnClk

If you want to send messages to the flash player, you will have to use FlashPlayer.window.handle, not getMainWnd().handle.

By handling the undocumented event "onMessage" of a window, you can drag only the sample movieclip. However, since swfkit will send mouse messages to the flash player when dragging, you cannot both block the mouse events and drag the projector. And although you can use the SendMessage api to send mouse events to the projector, if they are blocked, the flash player cannot receive them.

To both block the mouse events and drag the sample moveclip, you will have to write code in the "onMessage" event handler to move the main window by yourself (because if you set to ignore the mouse events, swfkit will not move the main window for you). But the "onMessage" event cannot receive the mouse move events, so it is impossible to drag the main window in the "onMessage" event handler at this time. If you really need this feature, we can rebuild swfkit to make it handle the mouse move events in the "onMessage" event handler.
Reply With Quote
  #8 (permalink)  
Old 05-24-2007, 12:37 PM
Member
 
Join Date: May 2007
Posts: 53
Default Re:Problem with Application.Interaction.lBtnClk

I have made my own drag manager.
Thank you!
__________________
#define true false //happy debugging, friends
Reply With Quote
Reply

Was this information helpful?    Yes No



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 04:17 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.