Skip to main content

All Questions

0 votes
1 answer
614 views

C++ Event Dispatcher - callback casting problem

I'm venturing into creating an EventDispatcher using C++ 17 in Visual Studio 2022. Basically I store a string (id) to identify the event and a callback (lambda, function or method of a class) in a ...
Donavan Carvalho's user avatar
1 vote
1 answer
996 views

EventCallback seems to be changing a parameter value on the razor page

I have a view in my project with 2 nested views/components (the main view contains a tree view and the tree view contains individual 'node' views for each object in the tree). I'm using event ...
Broad3857's user avatar
  • 443
0 votes
1 answer
313 views

How can I trigger a custom event and use it's callback return value NOW?

Normally I can do something similar (I could use array to manage multiple subscriptions) in vanilla js. window.doCensorship = function($value, $proposal){return true}; function canPublish(text){ ...
beppe9000's user avatar
  • 1,106
0 votes
2 answers
45 views

JS - Passing arguments through an eventHandler

I have a function to open a popup-window called "openPopup()". The popup has two static buttons: Cancel and Submit. The first parameter of the openPopup()-function is the content of the popup. The ...
Hustensaft's user avatar
4 votes
1 answer
654 views

Adding interaction in to a scene graph (in Haskell)

I've made a scene graph functional rendering engine in Haskell and am wondering how to add interaction in to the mixture. At first, I thought I could just have another Handler node which takes in one ...
Gentatsu's user avatar
  • 717
0 votes
1 answer
1k views

How to send a message to the class that created the object

I would like to send back data to class that create this object. It's game related. The enemy objects have a threaded function and move on their own in the scene. It generates lots of errors if you ...
NaturalDemon's user avatar
  • 1,004
1 vote
2 answers
3k views

Signals and Callbacks in C?

Is there any way to create callbacks and signals in C? I can use function pointer of course, but I want create a signal that can hold multiple functions i.e can bind to multiple events. Something ...
ApprenticeHacker's user avatar
2 votes
3 answers
1k views

How does on"XYZ" callback event work?

I'm looking for concept explanations or example code, if possible I'm new to (android) development and from what i've seen, there are a ton of "onEvent()" methods. for example, View.onClickListener(),...
David T.'s user avatar
  • 23.1k
13 votes
3 answers
10k views

How to reference an event in C#

I have the following class, which has one public event called LengthChanged: class Dimension { public int Length { get { return this.length; } set ...
Pierre Arnaud's user avatar
4 votes
1 answer
1k views

simple callback in visual c++

I'm a Linux programmer and new to COM programming and I've inherited a program which I'm now trying to modify. I've got an IDL file with the following dispinterface and I'm trying to set up a ...
Jayen's user avatar
  • 5,941