Event injection eats all the events

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

CanisMajorWuff
Just popping in
Just popping in
Posts: 6
Joined: Sat Aug 16, 2014 09:51

Event injection eats all the events

Postby CanisMajorWuff » Sat Aug 16, 2014 09:54

The problem that all mouse events which I pass to the CEGUI are returned with true.

I dont inject mousemove event, I inject mouseposition with absolute opengl canvas coordinates.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Event injection eats all the events

Postby Ident » Sun Aug 17, 2014 06:28

What event are we talking about?
CrazyEddie: "I don't like GUIs"

CanisMajorWuff
Just popping in
Just popping in
Posts: 6
Joined: Sat Aug 16, 2014 09:51

Re: Event injection eats all the events

Postby CanisMajorWuff » Thu Aug 21, 2014 20:48

I am talking about mouse key press, release.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Event injection eats all the events

Postby Ident » Fri Aug 22, 2014 06:55

You need to be more specific about what you are doing and what does not work. I cant help you based on your one to two line long posts.
CrazyEddie: "I don't like GUIs"

CanisMajorWuff
Just popping in
Just popping in
Posts: 6
Joined: Sat Aug 16, 2014 09:51

Re: Event injection eats all the events

Postby CanisMajorWuff » Fri Aug 22, 2014 11:12

Sorry, I was in a hurry.

In Cegui we need to inject mouse position and mouse buttons events. I did this.

My application has a rendering scene and gui small window to control the scene parameters, to see output by cegui.
The rendering scene has a camera, which rotations around x, y axis is produced by mouse movement (nothing special usual free camera).

It is necessary that cegui provide the application information was the mouse button pressed on the cegui window or outside of its area. Based on this the event could be send to camera controller or not.

But cegui always says true, that the application dont send events to camera event the mouse button pressed outside the gui.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Event injection eats all the events

Postby Ident » Fri Aug 22, 2014 11:16

CanisMajorWuff wrote:But cegui always says true, that the application dont send events to camera event the mouse button pressed outside the gui.


This sentence is so gramatically wrong that I cant understand what you are trying to say.

Regarding your injection of mouse inputs: Show your code.
Also if you do not soon correct your posts so they go along with our forum guidelines: http://www.cegui.org.uk/phpBB2/viewtopi ... =10&t=3351 I will stop replying. Do at least what our guidelines require as a minimum. So long it is only wasting our time.
CrazyEddie: "I don't like GUIs"

User avatar
Kulik
CEGUI Team
Posts: 1382
Joined: Mon Jul 26, 2010 18:47
Location: Czech Republic
Contact:

Re: Event injection eats all the events

Postby Kulik » Fri Aug 22, 2014 11:29


CanisMajorWuff
Just popping in
Just popping in
Posts: 6
Joined: Sat Aug 16, 2014 09:51

Re: Event injection eats all the events

Postby CanisMajorWuff » Fri Aug 22, 2014 19:16

Code: Select all

myRoot->setMousePassThroughEnabled(true);


Solves the problem. Thank you very much.

But I have the similar problem with keys. When I input text to for example a text field they key input propagates.

So

Code: Select all

_context->injectKeyDown


again returns true.

CanisMajorWuff
Just popping in
Just popping in
Posts: 6
Joined: Sat Aug 16, 2014 09:51

Re: Event injection eats all the events

Postby CanisMajorWuff » Fri Aug 22, 2014 20:16

I manage mostly to fix this either.

But have the a little issue. How to force a text field (for example from Editbox Taharez look) to lose focus.

I type something to it but cannot command it to lose the focus. I tried Esc, Return, double clicks in different places.


And question number two is: is it possible to catch events from see gui that it obtained/lost the keyboard focus?


Return to “Help”

Who is online

Users browsing this forum: No registered users and 25 guests