LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 02-09-2011, 09:33 AM   #1
nadavvin
Member
 
Registered: May 2006
Distribution: ubuntu
Posts: 109

Rep: Reputation: 21
totem python plugin programming: is there any signal for video mouse click?


Hello

I want that I click with the mouse on the video, it paused.

I notice that there is "BaconVideoWidget" which I guess is the video rendering widget but it don't have signal named "clicked":

Code:
vd = totem_object.get_video_widget()
vd.connect("clicked", vd.hide)
TypeError: <__main__.BaconVideoWidget object at 0x93db144 (BaconVideoWidget at 0x8857128)>: unknown signal name: clicked
Thanks
Nadav
 
Old 02-09-2011, 04:04 PM   #2
Snark1994
Senior Member
 
Registered: Sep 2010
Distribution: Debian
Posts: 1,632
Blog Entries: 3

Rep: Reputation: 346Reputation: 346Reputation: 346Reputation: 346
I assume from your tags (and from what I know about totem) that you're using pyGTK... That might have been something that you want to mention in your post

This isn't something that you will be able to do through the totem widget, AFAIK. You would set up an event handler on the window (http://www.pygtk.org/pygtk2tutorial/...tHandling.html) and then check if the click falls inside the totem widget. It's been a while since I had a look at pyGTK, you may even be able to check only for clicks that fall inside the widget itself

Hope this helps,
 
Old 02-11-2011, 02:01 PM   #3
nadavvin
Member
 
Registered: May 2006
Distribution: ubuntu
Posts: 109

Original Poster
Rep: Reputation: 21
How do I catch the event of the click on the window?

I didn't found single of it in gtk.window and its parent widgets.

http://www.pygtk.org/docs/pygtk/class-gtkwindow.html

http://www.pygtk.org/docs/pygtk/clas...s-gtkcontainer

http://www.pygtk.org/docs/pygtk/clas...ypes-gtkwidget

found button-press-event although I didn't success to click on anything to trigger it

Last edited by nadavvin; 02-11-2011 at 02:17 PM.
 
Old 02-12-2011, 10:09 AM   #4
Snark1994
Senior Member
 
Registered: Sep 2010
Distribution: Debian
Posts: 1,632
Blog Entries: 3

Rep: Reputation: 346Reputation: 346Reputation: 346Reputation: 346
Did you read the link I posted?

If you did, you'll find reference to the EventBox (which you may not even need, depending on how the video widget is written), and sample code of how to connect an event-handling method to the 'button-press-event' that you mentioned.
 
  


Reply

Tags
gtk, plugin, python, totem


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
compiz-fusion-extra-plugin mouse left click only grabs doesn't select Fr4zr Linux - Software 0 12-22-2010 07:11 AM
Single mouse click acts as a double click Aquarius_Girl Linux - Hardware 9 08-31-2010 01:50 AM
Totem youtube plugin 'Error Looking Up Video URI' stozi Linux - Newbie 1 03-12-2010 05:34 PM
middle mouse click is replaced by the dual click wanas Linux - Desktop 2 05-15-2009 04:53 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 03:20 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration