Hi all,
Had a look over SO but I can't see any threads which address my problem.
I have a conceptual architecture, where there is a central server, which allows clients to connect to it via XML web services. There are 2 types of client, producers and consumers.
The system is built in C# using WCF WebServices, specifically IIS webservi...
I'm making a Gui API for games. Basically I have event callbacks in my class which are function pointers. I thought of directly letting the user = the function pointer ex:
widget->OnPaintCallback = myPaintFunc;
But I don't like how I cannot check for NULL or do anything else. It also makes my class feel exposed.
I also thought of hav...
Hi,
I often need to create single events that are not needed after they have run once. The way I do is something like:
A.prototype.someMethod = function () {
var me = this;
this.onWindowMouseUpFunction = function () {
me.onWindowMouseUp.apply(me, arguments);
};
window.addEventListener('mouseup', this.onWindowMou...
I want to add separate event listener to dynamically created list of textview. The code so far is like this:
while (cur.moveToNext()){
TextView tv = new TextView(this);
temp = cur.getString(cur.getColumnIndexOrThrow("_ID"));
result = "some text";
tv.setText(result);
tv.setOnClickListener(new View.OnClickListener() {
...
I'm trying to create an array of JLabels, all of them should go invisible when clicked. The problem comes when trying to set up the mouse listener through an inner class that needs access to the iteration variable of the loop used to declare the labels. Code is self-explanatory:
for(int i=1; i<label.length; i++) {
label[i] = ...
Hi,
I have a complicated UI structure which is manipulated dynamically, and say I have an ui_state object where i keep user's latest UI states such as which tab was visible, what was inside that tab etc.
For instance:
var ui_states = {
tabs : [
{
name : "some tab",
active : true,
children : { ... }
}...
For some reason, my onclick javascript event handlers are not functioning properly.
Here is my markup, script and style:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Quadratic Root Finder</title>
<script>
document.ready = function() {
document.getElementById('calculate')....
I'm writing a wrapper in .NET (C++/CLI) to be able to use some native C++ Qt code in .NET. How can I map a Qt signal into a managed .NET event, so that when my Qt code fires off a signal, I can bring this forward to the .NET code.
My Managed class defines the event, but if I try to use the normal QObject::connect method to hook up to th...
Hi all,
I am trying to close all opened listeners using something like :
GP.GlobalInfo.CommWCF.serviceClient.GetFilteredMessageCompleted -= new EventHandler<GetFilteredMessageCompletedEventArgs>(serviceClient_GetFilteredMessageCompleted);
Since the form is being closed, every listener should be closed as well. (am I right?)
Since ...
public void itemStateChanged(ItemEvent event)
{
if(event.getSource() == doctorBox)
{
if (doctorBox.isSelected() == true)
JOptionPane.showMessageDialog(null, "you are a doctor");
else if (doctorBox.isSelected() != true)
JOptionPane.showMessageDialog(null, "you are not a doctor");
}
}
w...
Hi, I am developing an AIR app. In the main app I have a module loader 'mainModuleLoader'. I am creating modules as separate mxml files using the <mx:Module> tag. And I am loading such a module in mainModuleLoader dynamically using actionscript. Everything works fine.
For the module which I am creating as mxml files, I would like to kno...
I am writing an add-in that needs to log when a PST is added/removed via the "Data File Management" menu or through AddStore/RemoveStore. I have been having difficulty on finding documentation on how to capture these events.
Advice is greatly appreciated.
Thanks,
Larry
EDIT: Here's my dummy code that's not working:
using System;
us...
I have a form with about 40 checkboxes. Once a checkbox is checked, the div control's property should be changed from "none" to "block" or vice versa. I don't get an error, but the checkedchanged event isn't handled. Here is the markup:
<tr>
<td class="sectionSubHeader lightgrey">
<asp:CheckBox ID="chkbxCOMAEFund" AutoPostB...
How to make the update immediately when the jSpinner value was changed.
ChangeListener listener = new ChangeListener() {
public void stateChanged(ChangeEvent e) {
jLabel.setText(e.getSource());
}
};
spinner1.addChangeListener(listener);
The code above doesnt change the label text automatically, it required you to click again ...
I've got a set of Images and would like to know which I have touched. How could I implement that ?
To be more precise:
A "Home-Class" will instantiate a couple of Image-Classes:
Image *myImageView = [[Image alloc] initWithImage:myImage];
The image-class looks something like this:
- (id) initWithImage: (UIImage *) anImage
{
i...
Hi,
I have certain Keyboard shortcuts (ctrl+Key presses) in my Silverlight app which I use to do certain actions using Input Bindings. Now I am trying to monitor what are the shortcuts used most often. I do not want to explicitly log when the user invokes a input binding . I want it to be more generic. Now my question has two parts:
I...
When another application asks my application to open files, I need to find out which app is the source, because different courses of actions are taken. In
- (void)application:(NSApplication *)sender openFiles:(NSArray *)filenames
the code is currently:
NSAppleEventDescriptor *currentEvent = [[NSAppleEventManager sharedAppleEventManag...
Basically I want to assign events to some controls that are created. I want to update the labels associated with each trackbar when each trackbar is changed (change label1[i] and label2[i] when trackbar[i] changes). I have waded through google and I found that this probably has be done by using delegates. I had a blast using lambda expre...
I found this link to handle events for a dynamically created control in vb6 and I tried to use this for my code, but to no avail.
Option Explicit
Private WithEvents grid(0 To 23, 0 To 23) As Frame
How can I get the same functionality for this array of controls?
...
I attach an onmouseout event to a Raphael circle element like this:
(function(el,iElPos,col){
el.mouseout(function elmouseout(){el.animate({"fill":col,"r":ELEMENT_RADIUS},150);
alert("first");
fadeTag();
});
)(c,i,e...