events

jQuery event that triggers after CSS is loaded?

(I posted this on the jQuery forums but it's still awaiting moderation, so I thought I'd try my luck here since Stack Overflow is so awesome. If I get an answer I'll post it here.) I have a couple of links on my page (inside a <div id="theme-selector">) which allow you to change the CSS stylesheets: $('#theme-selector a').click(functio...

NAudio: How can I get an event that tells me that the MP3 file reached the end?

I tried to use this: private void CreateDevice() { _playbackDevice = new WaveOut(); _playbackDevice.PlaybackStopped += PlaybackDevicePlaybackStopped; } void PlaybackDevicePlaybackStopped(object sender, EventArgs e) { if (OnPlaybackStopped != null) { OnPlaybackStopped(this, e); } } But it never invoked. Th...

How to get the Blur event to fire for the document on the iPhone?

Does anyone know how to get the blur event to fire on the document for the iPhone? I'm trying to get it to fire either when a user changes windows in Safari, or when they open their bookmarks or when they decide to add the page to their homescreen. But none of these are firing it. Here's my code: $(document).blur( function () { ...

wxWidgets/wxPython: Do two identical events cause two handlings?

When there are two identical events in the event loop, will wxPython handle both of them, or will it call the handler only once for them both? I mean, in my widget I want to have an event like EVT_NEED_TO_RECALCULATE_X. I want this event to be posted in all kinds of different circumstances that require x to be recalculated. However, eve...

Possible to modify DOM during/before initial DOM parsing?

Is it possible to modify the DOM during or before the initial DOM parsing? Or do I have to wait until the DOM is parsed and built before interacting with it? More specifically, is it possible to hinder a script element in DOM from running using userscripts/content scripts or similar in chrome or firefox? Tried using eventListeners on DO...

Jquery binding event on selected class

Is it achievable in jquery to bind an event to a group of control that has certain class? It seems to me, it can't. I google a bit and all that came up are nothing to do with events. Here's how my code looks - $('.numonly').bind('keypress',function(event){ if (event.which > 31 && (event.which < 48 || event.which > 57)) return false;...

How to simulate array of events in C#? (like in VB6)

I have an object with event handlers and I want to make something similar to VB6 to make array of that object. Something like: MyHandler(object sender, MyEventArgs e, int IndexOfObject) <- ...

C# Event Handlers Using an Enum

I have a StatusChanged event that is raised by my object when its status changes - however, the application needs to carry out additional actions based on what the new status is. e.g If the new status is Disconnected, then it must update the status bar text and send an email notification. So, I wanted to create an Enum with the possibl...

How to make jquery bind event work

For some reason my bind events won't work. You can see my code here: http://dl.dropbox.com/u/145581/MyPage/default.html Clicking on 'Add gadget' or the 'Remove gadget' button should be firing alerts but nothing happens. Any ideas ? ...

How to Create a use defined Event and send it ?

Hi, flocks, Is there anyone could help me ? i want to send a use defined event and get it in iphone. how to create a use defined event in iphone development? ...

Jquery: encasing div and anchor link binded to same event.

im having trouble figuring out how to bind mouseout() to my entire nav bar including the links. when a user hovers over a link in #nav a sub menu is shown. all is well there. what i want to do is fadeOut that sub menu when the user hovers out of the entire #nav. my code for the mouseout: $('#nav').mouseout(function() { setTimeou...

Javascript Event for Select element Selection

Hi everyone, I'm looking to find the Javascript Event I need to put into jQuery's .bind function in order to have the function triggered when a selection is made from a <select> element. At the moment I'm using .bind('change',function() { ...}) but I need the event to trigger when the selected option is chosen again. Any suggestions? ...

C# event handlers not thread safe?

So i've read around that instead of calling a event directly with if (SomeEvent != null) SomeEvent(this, null); i should be doing SomeEventHandler temp = SomeEvent; if (temp != null) temp(this, null); Why is this so? How does the second version become thread safe? What is the best practice? ...

WPF: How to get the event when one FrameworkElement comes in contact with other FrameworkElement

I am developing a small application with images and trash box icon on right hand bottom. I have multiple images floating in the main window, and using mouse I can move image from one corner to other corner of window, left, right, top and bottom. I can't figure out how do I catch an event when a image touches and panel (with trash box ...

How to disable Events for a while in Javascript or jQuery

Hello, I am wondering if you guys know different approach to disable an event for a while. Let me elaborate this more : Lets say I have a div or button which has a subscriber to its onclick event. To prevent the double click when the the methods are doing some ajax things, these are the some of the ways we can do : Disable the button...

The Main Purpose of Events in C#

I've been examining one of my c# books and I just saw a sentence about Events in C#:  The main purpose of events is to prevent subscribers from interfering with each other. Whatever it means, yeah actually events are working pretty much like delegates. I've been wondering why I should use events instead of delegates. So is there any o...

Events in ExtJs

I have two windows. Event called in the one window, but handler (listener) must be in the other window. Can this be done? If yes, how to? ...

Getting the right result of mouse click event

Hello, I'm curious why I got the "right" BUT "wrong"number of result when I click the mouse. I supposed to print on the console mouseClicked once everytimes the mouse is clicked. However I got many of them printed out everytimes I clicked the mouse ...sometimes 5 e.g. mouseClicked mouseClicked mouseClicked mouseClicked mouseClicked I...

jquery load event sometimes dont work, why?

hi! i use something like this $(img).bind('load',function(){ console.log('loaded'); }); and obviously it works, but when the page is loading images from cache the event isn't triggered. how can i fix this situation? ...

log4Net EventlogAppender does not work for Asp.Net 2.0 WebSite?

I have configured log4Net EventLogAppender for Asp.Net 2.0. However it does not log anything. I have following in my Web.Config. <log4net> <appender name="EventLogAppender" type="log4net.Appender.EventLogAppender"> <param name="LogName" value="Test Log" /> <param name="ApplicationName" value="Test-Web" /> <layout t...