Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details

If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.

OSM (On Screen Menu)

Questions and comments specific to a particular plugin should go here.
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Thanks Pako, this works great!

I used your OSM plugin and a timer to make my own multi-tap logic to enable t9-like typing of letters through my RC's numpad. I am happy with it now. The only slight problem is performance due to the frequent window focus switching. I have just now noticed that your Multitap plugin could do the same so I may give it a try later.

Sorry to digress but since you have been actively putting out new eg releases, could you also consider my two other requests for inclusion in the next release?
viewtopic.php?f=10&t=3317
viewtopic.php?f=9&t=3316
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: OSM (On Screen Menu)

Post by Pako »

skat wrote:Sorry to digress but since you have been actively putting out new eg releases, could you also consider my two other requests for inclusion in the next release?
viewtopic.php?f=10&t=3317
viewtopic.php?f=9&t=3316
I incorporate your modifications into the next release (if I do not forget).

Pako
You know flattr ? You can Image
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Hi Pako,

Would it be possible for you to trigger an event if the user has moved the selection in the menu?

Thanks.
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: OSM (On Screen Menu)

Post by Pako »

skat wrote:Would it be possible for you to trigger an event if the user has moved the selection in the menu?
Well, certainly it could go do it.
But for what purpose is it useful?
Can you give an example of use?

Pako
You know flattr ? You can Image
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

I have a timer associated with the menu that I would like to restart every time the selection is moved. Since the user can also move the selection by using a standard up/down keyboard keys my script is unable to capture that.
Another use case is to display an additional OSD help for each menu item. Again if the user uses a different means of input to move the selection, there is no way to sync the OSD.
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: OSM (On Screen Menu)

Post by Pako »

OK, you can download new version from SVN repository and testing it.
Please tell me the outcome of tests!

Pako
You know flattr ? You can Image
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Pako, You are a legend! It works really well.

If you are going to upload a new release, please don't forget to include my two update requests above.

Thank you.
altainta
Posts: 29
Joined: Sun Nov 28, 2010 5:58 am

Re: OSM (On Screen Menu)

Post by altainta »

Hello again pako,

I would like to make a request for this plugin kindly consider please
Can you include Skin for this Plugin ? (like the skin for the OSD)
Also please put a option for changing and selecting a new skin...

Thank you pako you are great
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Hi Pako,

Any plans to compile and release a new eg version with the previous amendments anytime soon?


Anyway, this one is a special request (nice-to-have): Would it be possible that when the OSM menu appears, that the active window focus would still stay with the active application?

What is happening now is that OSM becomes the active window in the foreground acquiring the focus (Task.Activated.EventGhost event arrives). The problem is that if some applications have a special processing when losing window focus, eg. validating an input field, my OSM effectively triggers this and removes the cursor from the field so I am unable to insert some text back at that specific position anymore. I guess this may require SW_SHOWNOACTIVATE in the ShowWindow Win32 API (http://stackoverflow.com/questions/1560 ... focus-in-c) but it would be a great option to have if possible.
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Just had a look at the source code and the following would work for me (just search for "Raise" in the __init__.py):

# self.Show(True)
# self.Raise()
eg.WinApi.Dynamic.ShowWindow(self.GetHandle(), 4)

It would be great if this could be controlled by a parameter "Do not focus".
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: OSM (On Screen Menu)

Post by Pako »

When I'll have some good opportunity, so I look at it.
But I can not promise anything in advance.

Pako
You know flattr ? You can Image
skat
Posts: 48
Joined: Thu Jun 23, 2011 10:11 am

Re: OSM (On Screen Menu)

Post by skat »

Thanks Pako, it would be great to have that option.
User avatar
wakko
Posts: 33
Joined: Sat Aug 20, 2011 9:27 pm
Location: Russia, Siberia

Re: OSM (On Screen Menu)

Post by wakko »

Hello.

I'm trying to use OSM plugin on an old, AMD3000+ computer with 256mgb DDR400 memory with Gigabyte k8ns with socket 754 mother board. Windows XP prof SP3. EventGhost_0.4.1.r1534
Before that, i wrote and tested config file for EventGhost on C2D 6300 CPU, and it's working just fine on C2D.
But on old AMD i catched a problem.
If i use OS Menu, and press OK button on remote (OS Menu Ok action), sometimes it gives an error. It happens absolutely unpredictable. Sometimes it working as expected. But more often it gives errors.
If it's not working, it's gives a following error:

Code: Select all

         Error in Action: "OS Menu: OK"
         Traceback (most recent call last) (1534):
           File "C:\Program Files\EventGhost\eg\Classes\ActionBase.py", line 170, in CallWrapper
             return self(*args)
           File "C:\Program Files\EventGhost\plugins\OSM\__init__.py", line 1017, in __call__
             self.plugin.menuDlg.SendEvent()
           File "C:\Program Files\EventGhost\plugins\OSM\__init__.py", line 1278, in SendEvent
             self.SendEventSel(row)
           File "C:\Program Files\EventGhost\plugins\OSM\__init__.py", line 1230, in SendEventSel
             evtString = self.prefix.split(".")
           File "wx\_core.pyc", line 14610, in __getattr__
         PyDeadObjectError: The C++ part of the Menu object has been deleted, attribute access no longer allowed.
I found "work around" for that problem, but as i'm not a programmer, please, check, will it correct to use it?
I'm only moved self.destroyMenu() from the top to the bottom of that piece of code:

Code: Select all

    def SendEventSel(self, sel):
#        self.destroyMenu()
        evtString = self.prefix.split(".")
        evtString.extend(self.choices[sel][1].split("."))
        evtString = evtString[-3:]
        if len(evtString) == 3:
            if self.mode:
                eg.TriggerEvent(evtString[1], prefix = evtString[0], payload = evtString[2])
            else:
                eg.TriggerEvent(".".join(evtString[-2:]), prefix = evtString[0])
        elif len(evtString) == 2:
            eg.TriggerEvent(evtString[1], prefix = evtString[0])
        self.destroyMenu()
Thank you.
User avatar
wakko
Posts: 33
Joined: Sat Aug 20, 2011 9:27 pm
Location: Russia, Siberia

Re: OSM (On Screen Menu)

Post by wakko »

Ok. Correct it or not, but it helped me out.
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: OSM (On Screen Menu)

Post by Pako »

wakko wrote:Hello.
I'm trying to use OSM plugin on an old, AMD3000+ computer with 256mgb DDR400 memory with Gigabyte k8ns with socket 754 mother board. Windows XP prof SP3. EventGhost_0.4.1.r1534
Before that, i wrote and tested config file for EventGhost on C2D 6300 CPU, and it's working just fine on C2D.
But on old AMD i catched a problem.
If i use OS Menu, and press OK button on remote (OS Menu Ok action), sometimes it gives an error. It happens absolutely unpredictable. Sometimes it working as expected. But more often it gives errors.
If it's not working, it's gives a following error ...
I'm sorry, but I completely overlooked your post. Thank you for reporting.
wakko wrote:I found "work around" for that problem, but as i'm not a programmer ...
It does not matter at all, also I'm not a programmer.
I look at it and probably in the next version will fix it.

Pako
You know flattr ? You can Image
Post Reply