Hello Alex
Sorry for not writing sooner, but I am not a member of this mailing list and
I don't know alot about pui yet, but since nobody else answered I thought
that I would try to help and forward the message to someone who knows.
Your Code:
if((ptype & PUCLASS_INPUT)==PUCLASS_INPUT){
((puInput *)pob)->acceptInput();
pob->setValue(vdefault);
pob->setLegend(vdefault);
// pob->setStyle(PUSTYLE_SMALL_BEVELLED);
pob->setCallback( cb_net_input_c );
}
One thing I think could be the problem is the ptype, I asume that is the
name of your class, if so then it should be something like
ptype->getType() & PUCLASS_INPUT. Have a look at the puFilePicker class, it
has a few examples in it about the types in it, there is nothing to do with
puInput but it may help you. I will try to find more information for you
about this, but look there you should see what I am talking about, goto the
cvs on the sourceforge page. In the src/pui directory look at puFilePicker.
Sorry I could not be more specific.
Ben
<ALEX>
Hi,
I am using puInput Fields in the Net-Part of my GuiMenu (see screenshot
tuxfleet.sourceforge.net/gifs/screenshot-gui-connect.gif)
The puInput Fields react on keypresses, I can move, edit, delete, when I
press return this puInput field gets deactivated, and another one
gets activated and the callback function called.
But I couldn`t get to react puInput on Mouseclicks.
Any idea what I could have done wrong?
I got plib from cvs, but found no puInput examples there.
(I also noticed that doc/index.html is somehow Steve Baker`s private
index
page from woodsoup, and not the plib index page?)
For my puInput, I`ve done (see
tuxfleet.sourceforge.net/doxygen/html/class_GuiMenu.html#a15)
if((ptype & PUCLASS_INPUT)==PUCLASS_INPUT){
((puInput *)pob)->acceptInput();
pob->setValue(vdefault);
pob->setLegend(vdefault);
// pob->setStyle(PUSTYLE_SMALL_BEVELLED);
pob->setCallback( cb_net_input_c );
}
and (see tuxfleet.sourceforge.net/doxygen/html/class_Engine.html#a31)
glutKeyboardFunc ( keyboard_c ) ;
glutSpecialFunc ( special_c);
glutMouseFunc(mouseevent_c);
glutMotionFunc(motionevent_c);
glutPassiveMotionFunc(motionevent_c);
Any ideas what I missed?
Alex
|