*

Welcome, Guest. Please login or register.

Get your own OLPC - Buy an XO laptop on eBay!
Pages: [1] 2
Print
Author Topic: Disable automatic border menu  (Read 29755 times)

Disable automatic border menu

yadeyrinii
Commenter

Posts: 16


December 19, 2007, 09:21:14 PM

The border menu is really great, however I think it's causing some problems with the mouse.

The mouse cursor gets teleported to the lower right constantly when using certain apps. I think this behavior would stop if I could stop the automatic pop up nature of the Sugar interface. Is there any way to do this, and also what is the manual keys to activate the border?

Thanks in advance,

yadeyrinii
Logged

#1 Re: Disable automatic border menu

Irish_Moss
Senior Contributor
**
Posts: 111


December 20, 2007, 12:39:49 PM

Use the Frame key, located at the upper right corner of the keyboard.
Logged

#2 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 04:32:47 PM

The Frame key is nice to lock the menu in place. However, The frame key for me doesn't keep it from "popping up" every time the mouse goes into one of the corners. It gets annoying in programs like Opera. Since the tabs are located at the bottom next to the edge of the screen, it is difficult to position the mouse over the tab without bringing up the menu.

If there was a way to disable the automatic popping up, I'd LOVE to try it out! I'd prefer to use the frame key whenever I wanted to access an activity rather than the auto-popup.
Logged

Feel the OLPC Love

#3 Re: Disable automatic border menu

Infamy
Contributor
*
Posts: 76


December 20, 2007, 05:25:44 PM

I don't have mine yet, but it would stand to reason that you would have a config file in your home directory for that. Since I don't have one, I can't tell you exactly what it is, but maybe someone else here can look around for the sugar config files

Cheers,

Infamy
Logged

1st day donor Smiley

#4 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 06:41:00 PM

It looks like the activities frame uses "Hot Corners" to initiate it:

http://wiki.laptop.org/go/OLPC_Human_Interface_Guidelines/The_Laptop_Experience/The_Frame

There are apparently 3 ways to activate it: hot corners, the frame button, or an alert (such as a battery).

There must be some place where "hot corners" can be disabled. Or, it may be in 4 locations that each individually need to be turned off  Huh
Logged

Feel the OLPC Love

#5 Re: Disable automatic border menu

Ben James Ben
Senior Contributor
**
Posts: 142



December 20, 2007, 07:11:13 PM

It looks like the relevant code is in /usr/share/sugar/shell/view/frame/frame.py:

Code:
  52     def mouse_enter(self):
  53         self._show_frame()
  54
  55     def mouse_leave(self):
  56         if self._frame.mode == Frame.MODE_MOUSE:
  57             self._hide_frame()

 266     def _enter_corner_cb(self, event_area):
 267         self._mouse_listener.mouse_enter()

I'm not in the mood to experiment, but it seems as if commenting out lines 52-57 would remove the hot corners functionality. Another option appears to be lines 266-267.

Also, I note that a /usr/share/sugar/shell/view/frame/frame.pyc file exists (compiled python). Modifying frame.py is probably not enough. You'll probably have to either remove the .pyc file or re-compile frame.py into frame.pyc. But, again, I'm not in the mood to experiment with this.
« Last Edit: December 20, 2007, 07:24:01 PM by Ben James Ben » Logged

#6 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 07:39:34 PM

EDIT: See my post below: http://olpcnews.com/forum/index.php?topic=389.msg3038#msg3038
I just talked with Phil_Bordelon and m_stone on IRC, and they recommended commenting out 104-107 of the frame.py, and then rebooting the XO. And...it worked! Now the Frame is only activated through the frame key in the upper right corner of the keyboard.

I haven't tried the lines you've suggested. However, the above is known to work.
« Last Edit: December 20, 2007, 08:58:03 PM by XOXOXO » Logged

Feel the OLPC Love

#7 Re: Disable automatic border menu

Ben James Ben
Senior Contributor
**
Posts: 142



December 20, 2007, 07:46:44 PM

Thanks. That makes sense, /usr/share/sugar/shell/view/frame/frame.py lines 104-107 looks like the code that actually connects the mouse-move-into-corner event with the show-the-frame action:

Code:
104
 105         self._event_area = EventArea()
 106         self._event_area.connect('enter', self._enter_corner_cb)
 107         self._event_area.show()

Your post also indicates that people don't have to worry about the *.pyc files. Perhaps they automatically get re-compiled upon boot.
Logged

#8 Re: Disable automatic border menu

Infamy
Contributor
*
Posts: 76


December 20, 2007, 07:48:18 PM

Very good. We should find a way to make this an option in future software updates, as I think going to this depth might lead to problems with users who are new to this sorta thing.

Cheers,

Infamy
Logged

1st day donor Smiley

#9 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 08:07:27 PM

If turning off hot corners was an option in a preferences list it would be *Much* easier to do than using Vi or some other editing program to manually comment it out. For us intrepid folk though, its not that big of a deal. But for people who don't feel comfortable doing it, it would be good to have something else. Either something in the GUI, or something that could be easily implemented in a one-liner on the command line.
« Last Edit: December 20, 2007, 08:09:01 PM by XOXOXO » Logged

Feel the OLPC Love

#10 Re: Disable automatic border menu

Infamy
Contributor
*
Posts: 76


December 20, 2007, 08:12:30 PM

Even if it were a very obvious text file in the home dir of the user, I think that would suffice. I don't think it is worth the resources and space to come up with some sort of UI for it. Just a list of options, nicely organized and commented.

Cheers,

Infamy
Logged

1st day donor Smiley

#11 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 08:33:06 PM

Hmm, it looks like commenting out 104-107 breaks the home button on both the keyboard and the frame. However, the network, group and activity buttons still work. Uncommenting them makes the button work again. Any ideas?
Logged

Feel the OLPC Love

#12 Re: Disable automatic border menu

XOXOXO
Contributor
*
Posts: 38



December 20, 2007, 08:54:13 PM

If you Comment out lines 56-57 in /user/share/sugar/shell/view/frame/eventarea.py , you get rid of the automatic frame *and* the home button works! I have so far not found anything else broken, so i would recommend this over commenting out 104-107/frame.py.
Logged

Feel the OLPC Love

#13 Re: Disable automatic border menu

Sherman
Commenter

Posts: 14


WWW
December 22, 2007, 12:11:29 PM

If you Comment out lines 56-57 in /user/share/sugar/shell/view/frame/eventarea.py , you get rid of the automatic frame *and* the home button works! I have so far not found anything else broken, so i would recommend this over commenting out 104-107/frame.py.
Are you sure? That would leave...
Code:
def _create_invisible(self,x,y,width,height):
  invisible= gtk.Invisible()
# invisible.connect('enter-notify-event', self._enter_notify_cb)
# invisible.connect('leave-notify-event', self._leave_notify_cb)
Those are lines 54-57 from eventarea.py.
Logged

Sherman Dorn
Tampa, FL
Sometime technophile
Sometime technoskeptic

#14 Re: Disable automatic border menu

rkevans
Contributor
*
Posts: 55


December 22, 2007, 08:01:35 PM

Are you sure? That would leave...
Code:
def _create_invisible(self,x,y,width,height):
  invisible= gtk.Invisible()
# invisible.connect('enter-notify-event', self._enter_notify_cb)
# invisible.connect('leave-notify-event', self._leave_notify_cb)
Those are lines 54-57 from eventarea.py.


That worked for me.  Home button works, hot corners are disabled. 
There's a fix requested for it.  http://dev.laptop.org/ticket/5629

Rick
Logged
Pages: [1] 2
Print
Jump to:  

Members
Total Members: 2405
Latest: sembik
Stats
Total Posts: 31943
Total Topics: 3843
Online Today: 27
Online Ever: 238
(April 18, 2011, 09:48:50 PM)
Users Online
Users: 0
Guests: 15
Total: 15