listener

What are the default listeners in TestNG, and where do I find this list?

I was curious to know what the default listeners are in TestNG. I saw a bool property on the Ant task for useDefaultListeners but I would like to know what these are and where I can find them. ...

Destory JMS Message Listener

Hi, How to destroy my JMS Message listener ? I tried writing a code to set it to null, but that does not help ...

ExtJS: remove a grid from a tabpanel when its underlying store is empty

Hi, I have TabPanel which contains, among other things, a Grid connected to a Store. Several events may remove elements from the store. I would like the Grid to be removed from the TabPanel when the store is empty and, possibly, to have a single place in my code to check for this event. I thought about using store listeners, but unfo...

How can I filter the WCF Trace?

I need to get the following information during tracing: 1. I need to know how long an operation was executed. 2. I need to know if the operation(method in the service) is executed successfully. 3. I need to know if there's an error. I know that we can see all of that using the Service Trace Viewer, but is there a way that I can filte...

Updating a JSP with messages received in Java (writing a messenger client)

Hi all, this is my first question here - hope I'll get started on a positive note. Refrasing (since I am still stuck): I am writing a IM client via the XMPP protocol to connect to a Openfire server. For this I am using the Smack API. There are two ways of checking if new messages have been received: registering a listener with the XMP...

How to do something like listener of creating instances in other module?

Hello, I have module GUI, which has JTRee. And 2nd module creates ArrayLists of my own defined objects, which have some structure. For example car = new Car(); car.addEngine(new Engine("eng")); car.getEngine("eng").addWheel(new Wheel()); How to do my JTree in GUI module listens creating of objects in 2nd module and adding it to JTree? ...

Java: how to register a listener that listen to a JFrame movement

How can you track the movement of a JFrame itself? I'd like to register a listener that would be called back every single time JFrame.getLocation() is going to return a new value. EDIT Here's a code showing that the accepted answered is solving my problem: import javax.swing.*; public class SO { public static void main( String[] ...

Is it possible to listen to relational database update?

Is it possible to listen to relation database update? For example, my web app want to send data update to client through Comet technology. I can have the program to poll the database periodically, but that would not be performant and scalable. If app can hood to a "event handler" of database, then app can get notification every time gi...

Why is my onItemSelectedListener not called in a ListView?

I'm using a ListView that is setup like this: <ListView android:id="@android:id/list" android:layout_width="fill_parent" android:layout_height="fill_parent" android:longClickable="false" android:choiceMode="singleChoice"> </ListView> In my code I add an OnItemSelectedListener to the ListView like this: getListView().setAdapte...

Need events to execute on timer events, metronome precision.

I setup a timer to call an event in my application. The problme is the event execution is being skewed by other windows operations. Ex. openning and window, loading a webpage. I need the event to excute exactly on time, every time. When i first set up the app, used a sound file, like a metronome to listen to the even firing, in a stead...

jquery listener don't "listen" to events on DOM elements dinamically created

Hi, i have a listener like this: $('.delete').click(function() { ...some stuff }); also, on the same page, another script dinamically add elements to the DOM in this way: $('#list').append('<tr><td><a class="delete" href="#">delete</a></td></tr>'); my problem is that the listener doesn't "listen" to these dinamically created ele...

Modifying JSF Component Tree in PhaseListener

Hi all, I'm having an issue. I've implemented a PhaseListener, which is meant to add a style class to any UIInput components in the tree that have messages attached to them, and removes the style class if it doesn't have any messages attached to them. The PhaseListener runs in the RENDER_RESPONSE phase, and does it's work in both the...

In Swing, what is the best listener to use in a textarea

I am trying to change the font of the text in a textarea in Swing. Which listener should I use on textarea to trigger an action that lets the program initiate the font code. All the examples have all the swing in the same class which lets you access the textarea directly, but I have multiple classes; I know I can pass the textarea in an...

UITableView - listen to bounce?

Hallo all. Ist there a way to listen to the event when a UITableView bounces back? I want to be notified, when the User releases the Table and it scrolls back to the top, i.e. he/she dragged it down so far, that one can see the background behind the table. Is there a good way to 'listen' to this and be notified? E.g. via a listener, de...

Threads: Just what is it that makes them confusing? Two Runnables with Mouse Listener

I have a JWindow and a JFrame both I have made runnable and both implement a mouse listener. I have alot of testing to do for a project of mine and to simplify it I wish to be able to automate most of it, so I have starting my own mouse recorder and replayer (uses Java Robot Class). Kinda like a simplified AutoHotKey or AutoIt thing... ...

Problems with registering click event listener to a frame-element

Hi everybody, I ran into a problem with adding an event listener. I wrote a Firefox plugin a while ago for my bachelor thesis. It was based on a different attacker model than you would normally expect. In this scenario the attacker was the service provider (like Facebook, Google,...), who reads all your private data stored on their site...

is there an equivalent to a "Focus Listener" in Objective-C or iPhone SDK? (Coming from Java)

Hello. I am a student programmer who has taken up Objective-C on my free time as my college doesn't teach it. We have only used Java and basic C so far. I am in the middle of making a program for the iPod and was wondering if there was any type of way to call a method in a class similar to the way a Focus Listener does in Java? I hav...

Registering a Named Function as a Listener with Jquery

I'm new to javascript/jquery and I've done some poking around the web, but I can't figure out why the following is invalid: var toggleSection = function(sectionName) { // Do some Jquery work to toggle stuff based on sectionName string // (concatenate sectionName with other text to form selectors) }; $('#togglecont1').click(toggleSection...

how to implement listener?

Hello, I have some dynamic tree. And now I need to implement some functionality, that happend every time, when simply click on node. (I mean only one click on node, which "makes it blue") *EDIT2: * I use beanTreeView and package openide How to implement listener of this action? EDIT - added pseudocode public class MyNode extends Abst...

dynamically add listener to ajax created content in jQuery

I am trying to get the html value of a linked clicked. The links are created dynamically with Ajax so I don't think .bind will work and I don't have latest version with .live $('div#message').click(function() { var valueSelected = $(this).html(); // picks up the whole id. I juust want single href! alert(valueSelected); ...