events

Form_Load() 'event' or Override OnLoad()

I would like someone to try and explain the difference between these. More specifically, example usage scenario's. I am refactoring some Windows Form code and a Form has some code in the Form_Load() event and also in a protected override void OnLoad() event that calls base.OnLoad(e); Now I traced it and the Override fires first and ...

Swing/JTable Not Updating After Bound Data Fires Change

I have a JTable which is bound to my EventTracker bean, essentially a wrapper around a list which I will use as append/clear only (i.e., a simple log). Problem is, when I add entries to the list and try to fire an event I don't see any changes. I'm using the NetBeans IDE. The EventTracker bean is added to the view and instantiated as ev...

how to know following page

Is there's a way to know, in javascript, if the page will change ? During an event (ie a click) is there a way to know what is the coming page without checking element's href (if clicking on a link) or form's action (if submitting a form) ? ...

Make an event happen in child iframe to the parent window in JavaScript?

I don't have access to this iframe's source directly, so I would like to do this, if it's possibly this way. I have an iframe generated by JS: <iframe name="temp_iframe" width="100%" height="95%" src="'+the_url+'"></iframe> And inside is a submit button and a cancel button. The submit button works fine, but I want the cancel button t...

Call to GetData fails silently in DragDrop event

Hello, I am building a Winforms application with drag and drop support into a TextBox. The TextBox should allow files and text to be dropped onto it. Its AllowDrop property is set to true. This is the event handler for its DragDrop event: var validFile = e.Data.GetDataPresent(DataFormats.FileDrop); var validText = e.Data.GetDataPrese...

Magento: Obtain Id for order, listening to the event checkout_onepage_controller_success_action

Hi people, When I look at the event (checkout_onepage_controller_success_action) and works, but I can not get the Id of the newly created order. Anyone have any idea?? Use magento-1.4.1.0 Thanks ...

Is there an event for when garbage collection occurs in .NET?

I've got a weird slowdown in my ASP.NET website that I cannot seem to track down. I'm suspecting that GC might be kicking in and halting my threads. To know for sure it would be nice to log every time when GC does occur. I could make a dummy object and do the logging in its finalizer, but that would then be a one-shot solution, while in...

iphone - determine if touch occurred in subview of a uiview

In a subclass of UIView I have this: -(BOOL)pointInside:(CGPoint)point withEvent:(UIEvent *)event { if(touch occurred in a subview){ return YES; } return NO; } What can I put in the if statement? I want to detect if a touch occurred in a subview, regardless of whether or not it lies within th...

Very hard to capture double tap on UIButton subclass. (time delay to capture double tap)

Im talking about two separate touches on the screen with the same finger I think i have the coding right for this. but it is almost impossible for me to actually generate a double tap on my iPad. Is it possible to increase the time interval between a single and double tap, so it is easier to trigger. I do a double tap very fast and it c...

Is there a dual thumb slider (also known as a range slider) that responds to touch events?

YUI 3 just recently came out with touch event support for their slider, so that it can be manipulated using touch screens on mobile devices like iPhones and Android. However, it might be a while before there is a dual thumb slider (aka "range slider") made within the YUI 3 framework. Possibly it will take longer than the deadline for my...

Swing event not fired by a user

Which are other events than timer not fired by user interaction but automatically by the system? ...

Send an event to call a method between two classes

How can I invoke a method in a class only after verifying a condition in another method of another class in my iPhone app? Any ideas? Thanks, Andrea edit 3 //class1 //Class1.m @implementation Class1 { .... [class2 method1:@"file1.xml"]; [class2 method1:@"file2.xml"]; [class2 method1:@"file3.xml"]; } …...

Notification when rendering a Visual in WPF is complete

Is there a way to get notified (e.g., by an event) when a Visual has been (re-)rendered? Basically, I would like to take a screen shot whenever a Visual's appearance has changed. I assume the rendering thread is taking care of this in the background. I am trying to avoid grabbing a screen shot periodically since I am only interested in...

Registering for GWT DOM Events

This might be a stupid question but I write a class called test lets say in GWT and I want to have it listen for DOM events. How would I do that? I have tried implementing lets say the KeyPressHandler and then implementing the method onKeyPress() and I place an Window.alert("Event") in the body. Though nothing happens when I test it pre...

Pros and Cons to use interface listeners

Which are, for every of the following methodology to implement an interface listeners, the pros and cons: 1) into the main class as: class MyClass implements ActionListener { public void actionPerformed(ActionEvent e) { // ... } component.addActionListener(this); } 2) as an inner class as class MyClass { pri...

C#: Create an event that is fired whenever another event that has listeners is fired, dynamically via reflection maybe?

Here's what I am working with: Part of my project is a windows form app. I want to basically capture every event that fires and has listeners. So some button's click event, some checkbox's check event, everything on a basic "Control" event list. So that event still fires, but also fires my event. Is there a generic "some event fired" ...

my C# winform needs to detect when other applications enter/exit/run-in TRUE fullscreen, prefer by events.

my C# winform application needs put itself in standby mode during time other application runs in true fullscreen mode (not only maximized), like video games, video movies, powerpoint. I need a method to detect if currently there is other application in fullscreen. Is there a possibility to register to events which will fire when other ...

pass an object through jquery trigger

I'm trying to do something rather simple but I'm getting a strange result. I have an event trigger that I'm using to pass a json object but when it gets through to the other side it's a function... I alert the result and it shows this: example of alert sting: alert('value of lattitude? ' + map.currentLatLng.lat); result: value o...

Event driven architecture...infinite loop

I have an event driven architecture where A is waiting for a change from B and B is waiting for a change from C and C is waiting for a change from A, forming a cycle. Now, if B changes, then A fires an event to C, which fires to B, which fires to A, which fires to C...ad infinitum. I can change my program right now to not contain thi...

Raising events so that they are handled on a the same thread as original subscriber

In dotNET with C# 4.0, How can I ensure that event that happens on an arbitrary thread X will call handlers in the same thread (or synchronization context) as the subscribing thread A, B, or C. I am trying to avoid having to put in threading-related code into handler method or event site. It would be really great if I wouldn't have to ...