Commit Graph

183 Commits

Author SHA1 Message Date
Maxim Ermilov
4456954d30 [panel] Only show starting applications for current workspace
Add the workspace we started on to ShellApp.  Use it inside panel.js
to filter the list.
https://bugzilla.gnome.org/show_bug.cgi?id=623688
2010-10-07 01:31:22 +04:00
Jason D. Clinton
b96cf2042a [StatusIconDispatcher] Add keyboard and display icons to tray icon list 2010-09-24 14:53:50 -05:00
Florian Müllner
8c1bf346a9 [appDisplay] Factor out WellGrid/AppIcon
All mockups now use a representation for documents/places similar to
the one used for applications. Rename AppIcon to BaseIcon and move its
code together with WellGrid out of appDisplay to stress their general
usefulness.

https://bugzilla.gnome.org/show_bug.cgi?id=625887
2010-09-23 19:08:43 +02:00
Dan Winship
cbf2cbac61 [StatusIconDispatcher] Move non-system-tray icons to message tray
New StatusIconDispatcher dispatches icons to the system or message tray.

Based on a patch from Matt Novenstern
https://bugzilla.gnome.org/show_bug.cgi?id=608869
2010-09-23 09:49:47 -04:00
Dan Winship
ae9360659d [ShellTrayIcon] add ShellTrayIcon, make ShellTrayManager use it
The actor emitted by ShellTrayManager is now ShellTrayIcon, a subclass
of ShellGtkEmbed which has several properties on it which are (or will
soon be) useful to the shell.

Part of the rearranging to use ShellTrayIcon means that we now show
the ShellEmbeddedWindow before creating its ShellGtkEmbed, which
requires a few modifications to ShellEmbeddedWindow (notably, telling
it at construct time what stage it will be drawn on, since it needs to
know that before it has a ShellGtkEmbed now).

https://bugzilla.gnome.org/show_bug.cgi?id=608869
2010-09-23 09:49:47 -04:00
Giovanni Campagna
6ea18136ac Add Universal Access status indicator
Introduce the Universal Access status indicator as designed, modeled
after the similar UI provided by g-s-d. This indicator allows the user
to change rapidly the keyboard and mouse behaviour (sticky keys, slow
keys, bounce keys, mouse keys), as well as the enabled ATs (magnifier,
screen reader, screen keyboard) and the HighContrast Gtk theme.

https://bugzilla.gnome.org/show_bug.cgi?id=624916
2010-09-16 15:03:26 -04:00
Florian Müllner
c18ff91030 [panel] Add a style class while the overview is active
Designers have asked for the possibility to style the panel
differently in the overview.

https://bugzilla.gnome.org/show_bug.cgi?id=624381
2010-08-20 12:06:48 +02:00
Giovanni Campagna
73ecdbd6da Add API for system status indicators
Add a container in the panel for holding them, a fast method for
loading and a simple base class to be subclassed by specific
implementations.

https://bugzilla.gnome.org/show_bug.cgi?id=621705
2010-07-21 12:31:06 -04:00
Dan Winship
539ad8196e [panel] don't empty out the app menu when the panel itself gets focus
https://bugzilla.gnome.org/show_bug.cgi?id=623429
2010-07-20 15:03:17 -04:00
Florian Müllner
4632db177a Clean up unused includes
Some late spring cleaning ...
2010-07-19 01:46:01 +02:00
Florian Müllner
cc0de39725 [panel] Fix translatable string
Fix a string which is not extracted correctly by marking it
correctly with double quotes.
2010-07-19 01:46:01 +02:00
Giovanni Campagna
5a7201ef4d Resolve cyclic dependency on StatusMenu
Solved by splitting the base class (PanelMenuButton) in a separate
module, ui.panelMenu, which is meant to hold also other reusable
button classes.

https://bugzilla.gnome.org/show_bug.cgi?id=621705
2010-07-13 11:58:13 -04:00
Florian Müllner
69fde6822c [StartupNotification] Do not bounce the animation
The spinner animation moving from left-to-right to indicate a starting
application changes its direction on reaching the end of the movement.
Instead, keep the spinner at the right of the app name until startup
has finished.

https://bugzilla.gnome.org/show_bug.cgi?id=623687
2010-07-10 02:25:58 +02:00
Florian Müllner
81aed78a1f [panel] Flip left and right group in RTL locales
While the contents of the left and right group in the panel are
flipped correctly, the groups themselves have to be swapped as
well. The location of the hot corner has to be corrected as well.

https://bugzilla.gnome.org/show_bug.cgi?id=622243
2010-06-21 18:40:29 +02:00
Milan Bouchet-Valat
2799327c84 Migrate to GSettings
Use GSettings for all Shell configuration. GConf is kept to read
configuration from external programs (Metacity, Nautilus and Magnifier),
but ShellGConf is removed because it's mostly useless for the few calls
we still have. Also get rid of unused GConf code in ShellAppSystem.

A basic GConf schema is still used to override Metacity defaults and
configure Magnifier in a system-wide fashion. GConf is also used as
GSettings backend via the GSETTINGS_BACKEND environment variable.
All of this will be removed when these programs have been ported
to GSettings and able to use dconf.

GLib 2.25.9 is required. Schemas are converted to the new XML format,
and compiled at build time in data/ so that the Shell can be run from
the source tree. This also requires setting the GSETTINGS_SCHEMA_DIR
environment variable both when running installed or from source tree,
in src/gnome-shell.in and src/gnome-shell-clock-preferences.in.

https://bugzilla.gnome.org/show_bug.cgi?id=617917
2010-06-18 20:27:41 +02:00
Maxim Ermilov
7f8f0f2358 Add animated display of startup notification
The shell design says that upon launching an application,
no X window should have focus, and we should display an
animated launching indicator.

Implement this by in panel.js, keep track of the last started
application.  If there isn't currently an X focus, show an animation
for the last starting application.

https://bugzilla.gnome.org/show_bug.cgi?id=598349
2010-06-17 23:18:28 +04:00
Florian Müllner
9baf8e19ea Kill Ubuntu indicators on start-up
Canonical replaced status icons with libindicator based solutions,
which don't work in the shell environment. Force the distro-patched
versions to fall-back to upstream.

https://bugzilla.gnome.org/show_bug.cgi?id=621382
2010-06-17 18:44:50 +02:00
Dan Winship
7fbf8ae4c9 [popupMenu] split this out from panel.js
We want to use this menu style in other places as well

https://bugzilla.gnome.org/show_bug.cgi?id=619541
2010-06-10 15:04:42 -04:00
Colin Walters
e4a6bf994f Fix ShellAppSystem's use of no_focus_window, clean up state handling
First, we were passing an incorrect timestamp to
meta_display_focus_the_no_focus_window - fix that.

The invocation of set_focus_app to the started app there couldn't
really work, because (if the above call had worked) we'd get the
X reply *after* the started app.

What we need to untangle here is the distinction that's now made in
ShellApp between _STATE_STARTING and _STATE_RUNNING.  A nice way to
start doing this is to rebase ShellWindowTracker to only be concerned
with app states.  Concretely, the current "has windows implies
running" logic now lives just inside shell-app.c.

Rename the app-running-changed signal to be app-state-changed.  This
will ultimately be useful so that inside the panel, we can track
the last started app.

https://bugzilla.gnome.org/show_bug.cgi?id=620899
2010-06-09 14:44:15 -04:00
Florian Müllner
e1a109b9be [panel] Fix translatable strings
There are some strings in panel.js which are not extracted correctly.
Fix by marking them correctly with double quotes and _().
2010-06-08 17:13:26 +02:00
Florian Müllner
63d84533c9 [ClockButton] Add a right-click menu to the clock
The clock preferences are hardly discoverable, so allow launching
them from a right-click menu.

https://bugzilla.gnome.org/show_bug.cgi?id=600276
2010-06-03 11:43:58 +02:00
Raphael Bosshard
e3eaa69948 Add ISO week dates to the calendar
This patch adds ISO week dates to the calendar. Week dates are an
often used feature in business and government offices. Can be turned
on through gconf, off by default.

https://bugzilla.gnome.org/show_bug.cgi?id=603532
2010-05-28 01:31:33 +02:00
Florian Müllner
a0be7fa455 [panel] Hide application menu in overview
The activities overview is not a place where we expect users to
interact with a specific application, so showing the application
menu there is misleading.

https://bugzilla.gnome.org/show_bug.cgi?id=618479
2010-05-26 14:06:53 +02:00
Colin Walters
01c493565f [panel] Ellipsize long application titles, don't push clock around
First, simply set the ellipsize flag on the application menu labels.
Next, rework how we lay out the panel components so that the center
box is always centered and constrains the left and right, rather
than pushing it around.

Previously, as part of making the shell not obviously explode if
one had a lot of tray icons, we allowed them to push the clock over.
Instead, go back to just failing in this case; we need to exile legacy
tray icons, not be slightly less ugly.

https://bugzilla.gnome.org/show_bug.cgi?id=592640
2010-05-25 10:40:15 -04:00
Dan Winship
fff04d51b7 [panel] fix alignment of app menu label
we were aligning the top of the shadow with the top of the other labels,
rather than aligning the label itself

https://bugzilla.gnome.org/show_bug.cgi?id=618793
2010-05-25 09:34:01 -04:00
Christian Schramm
91319d5da2 changed 'y_fill' of '_clockButton' in panel to false
The clock appeared to high compared to the activities button
or the login name. Might be just me though.

https://bugzilla.gnome.org/show_bug.cgi?id=619144
2010-05-20 13:01:45 -04:00
Dan Winship
c8f4adde7f [panel] fix nested-queue_relayout warning in menus
We don't need to reposition the menu every time its button is
allocated; we can just stick it in the right place when we pop it up
(which is guaranteed to not be during a layout cycle).

(This means that now we won't reposition the menu if the button
moves/resizes while the menu is already popped up, but it's not clear
that we'd want it to anyway, since that could easily result in the
user selecting the wrong item, etc.)

Also, we don't need to override the menu's width any more, so remove
that.

https://bugzilla.gnome.org/show_bug.cgi?id=619113
2010-05-19 17:06:35 -04:00
Dan Winship
8b242dd4bd minor js cleanups
add missing semicolons pointed out by js2-mode, add missing emacs
modelines, fix a few tabs that crept in via cut+paste
2010-05-19 13:26:41 -04:00
Dan Winship
9b3e16595b [panel] add keyboard navigation of menus
https://bugzilla.gnome.org/show_bug.cgi?id=619008
2010-05-19 13:16:22 -04:00
Dan Winship
2179f5836e [panel] separate "active" state from hover state in PanelBaseMenuItem
When doing keyboard navigation, the active menu item may not be the
one under the mouse.

https://bugzilla.gnome.org/show_bug.cgi?id=619008
2010-05-19 13:15:46 -04:00
Dan Winship
320adb316d [panel] split out a PanelBaseMenuItem class
Make the existing PanelMenuItem, PanelSeparatorMenuItem,
PanelImageMenuItem inherit from it.

https://bugzilla.gnome.org/show_bug.cgi?id=619008
2010-05-19 13:15:46 -04:00
Colin Walters
db36a90c48 Combination of updates to match design suggestions
* Align the icons inside text
* Add application name to Quit
* Fade in/out the menu
* Drop some padding around the edges
* Add padding around the separators
* Use a gradient for separators

https://bugzilla.gnome.org/show_bug.cgi?id=618460
2010-05-19 12:31:19 -04:00
Dan Winship
1d721c9080 [panel] add some missing semicolons 2010-05-18 13:16:24 -04:00
Marina Zhurakhinskaya
703b21cef0 Don't use double quotes for things that don't need to be translated
This is our convention.

The only exceptions are double quotes for words in comments that give
them a special meaning (though beware that these quotes are not truly
necessary most of the time) and double quotes that need to be a part
of the output string.
2010-05-13 16:00:38 -04:00
Colin Walters
e835cd2c2d [panel] PanelImageMenuItem should follow gtk-menu-show-images
Update statusMenu to always show images for the presence items only.

https://bugzilla.gnome.org/show_bug.cgi?id=618438
2010-05-12 17:25:51 -04:00
Colin Walters
27bcce0888 [panel] Port user status menu to panel menu
https://bugzilla.gnome.org/show_bug.cgi?id=613804
2010-05-11 14:10:36 -04:00
Colin Walters
fdcb73d93e Make panel more menu-like, initial application menu
Change the panel into a menu-like actor, where elements can
add menu items.

Implement the initial application menu.

https://bugzilla.gnome.org/show_bug.cgi?id=613804
2010-05-11 14:10:36 -04:00
Owen W. Taylor
5111edb80b Use a St.Bin rather than a St.BoxLayout for calendar popup
Using a horizontal St.BoxLayout for calendar container forces
width-for-height layout on the St.Table child. Since St.Table
is naturally width-for-height, this can trigger bugs and is,
at best, a bit ineffecient. Use a St.Bin instead since we don't
need any BoxLayout features.

https://bugzilla.gnome.org/show_bug.cgi?id=618104
2010-05-09 16:37:08 -04:00
Florian Müllner
e6b91414de [panel] Make clock configurable via gconf
Add keys for customizing the panel clock to the gconf schema and make
the clock use them. The settings are copied from gnome-panel's clock
applet, excluding all location/weather/appointment/... keys. In addition,
'internet' is no longer a supported value for the format key.

https://bugzilla.gnome.org/show_bug.cgi?id=600276
2010-05-09 01:07:40 +02:00
Joseph Scheuhammer
62afd2ffa3 Reorganize stage in terms of a UI Group actor and everything else
In preparation for adding magnification, "uiGroup.patch", organizes the stage
along the following lines:

Stage
  *Magnifier
  UI group
    Window group
    Chrome group
    Overlay group
    Alt tab
    App display
    Chrome
    ...

This allows a magnifier actor to clone and magnify the UI group.  The magnifier
is a sibling of the UI Group in this stage oraganization -- see the next patch,
"Magnifier.patch".
2010-05-06 17:18:10 -04:00
Colin Walters
7d7ed7ce7a [panel] y_fill the calendar button 2010-04-27 13:07:31 -04:00
Colin Walters
704354be2c [panel] Remove hardcoded uses of PANEL_HEIGHT
It's cleaner to just y_fill.

https://bugzilla.gnome.org/show_bug.cgi?id=616951
2010-04-27 12:52:57 -04:00
Colin Walters
3715109ebe [panel] Fix allocation positioning for boxes
This change doesn't actually affect anything visibly, but
using the absolute coordinates of our allocation box in allocate()
is wrong; we should be positioning our children at 0,0 and using
width/height as a reference.

https://bugzilla.gnome.org/show_bug.cgi?id=616951
2010-04-27 10:37:17 -04:00
Colin Walters
6aaf4b87d5 Major ShellApp API cleanup, startup notification, window focus handling
This patch combines several high level changes which are conceptually
independent but in practice rather intertwined.

* Add a "state" property to ShellApp which reflects whether it's
  stopped, starting, or started.  This will allow us to later clean
  up all the callers that are using ".get_windows().length > 0" as
  a proxy for this property
* Replace shell_app_launch with shell_app_activate and shell_app_open_new_window
  A lot of code was calling .launch, but it's signficantly clearer
  if we call this ".open_new_window()", and later if we gain the ability
  to call into an application's menu, we can implement this correctly rather
  than trying to update all .launch callers.
* Because ShellApp now has a "starting" state, rebase panel.js on top of
  this so that when we get a startup-notification sequence for an app
  and transition it to starting, it becomes the focus app, and panel.js
  cleanly just tracks the focus app, rather than bouncing between SN
  sequences.  This removes display of non-app startup sequences, which
  I consider an acceptable action in light of the committed changes
  to startup-notification and GTK+.

https://bugzilla.gnome.org/show_bug.cgi?id=614755
2010-04-12 16:32:21 -04:00
Dan Winship
2320c393c9 Replace all remaining BigBoxes with StBoxLayouts or StBins
Also, remove a lot of cruft from genericDisplay.js leftover from
previous St-ifications, and remove the pre-gtk-2.16 hacks from the
status tray in panel.js (which are much less needed with the
nearly-all-black panel anyway).

https://bugzilla.gnome.org/show_bug.cgi?id=614516
2010-04-06 09:13:51 -04:00
Colin Walters
c92ce5983d Consume startup-notification APPLICATION_ID
This patch ensures we're showing the correct data when doing
startup-notification.

https://bugzilla.gnome.org/show_bug.cgi?id=612833
2010-03-30 17:36:05 -04:00
Colin Walters
087ac8470e [panel.js] Remove duplicated 'let'
Original fix from Maxim Ermilov <zaspire@rambler.ru>
2010-03-16 10:51:05 -04:00
Dan Winship
3ce89e3c80 Add missing semicolons noted by jslint
Taken from a patch by Lex Hider on the mailing list
2010-03-15 09:50:05 -04:00
Colin Walters
3aea09b614 Fix app icon fading
The way we were loading data into a CoglTexture, then pulling it out
and manipulating it on the CPU, then loading it back into a texture
was a bit lame.

Clean things up a bit here by loading directly into the CPU, doing
the fading, then creating a texture.

Also cache the faded data in StTextureCache.

https://bugzilla.gnome.org/show_bug.cgi?id=612759
2010-03-13 12:50:38 -05:00
Dirk-Jan C. Binnema
046e0609ab Improve 12/24 clock detection
The current check looks at whether there was some am/pm suffix in the
localized time; however in some cases (locales) that does not seem to
work. this version instead checks whether the localized versions of 05:00 and
17:00 start with the same two digits; if not, it's probably a 24h clock.

https://bugzilla.gnome.org/show_bug.cgi?id=603488
2010-03-05 12:02:18 -05:00
Colin Walters
347196d35c [panel] Fix RTL for appMenu, allocation, other misc.
Other misc includes:
* Remove some unused CSS
* Readd comments

https://bugzilla.gnome.org/show_bug.cgi?id=611288
2010-03-01 13:34:20 -05:00
Colin Walters
ae3d1423e5 [panel] Handle async load of icons correctly
Fading the application icon required the texture to have already been
loaded, which was normally the case since we create icons for apps
in the well and browser; but when finding an app not from there,
the cogl-texture for the icon might not be available.

Fix this by watching for the texture and fading when it appears.

https://bugzilla.gnome.org/show_bug.cgi?id=611288
2010-02-28 15:53:22 -05:00
Colin Walters
d56fbf6d6a [panel] Fix AppPanelMenu's allocation
Because we were setting the "fixed-position-set" property
on the internal label, its width/height requests weren't
being accounted for in the size request of the overall box.

The way we were hooking up to notify::allocation was hacky; do
this correctly by simply implementing a container.

https://bugzilla.gnome.org/show_bug.cgi?id=611288
2010-02-28 15:53:22 -05:00
Owen W. Taylor
38b7904f92 Distinguish translator comments for date formats
Don't say 'This is a time format' for both time formats, but
label them as 24-hour and AM/PM.
2010-02-11 14:53:14 -05:00
Colin Walters
c89ee2f8f2 [panel] Fix typo in previous clock patch
We shouldn't be displaying hours as 24 in am/pm case
2010-02-11 14:42:12 -05:00
res
c21e692652 [panel] Detect clock AM/PM from locale
Look at whether a localized time string from JS includes am/pm to
determine whether we should show it in the UI.
2010-02-11 14:01:19 -05:00
Owen W. Taylor
caaa543385 Draw a ripple when the hot corner is hit
Animate an expanding ripple from the hot corner using multiple
scaling copies of a PNG of a single ripple. The idea here is to
give the user a clue as to what happened.

Based on initial version implemented live at MIT IAP GNOME Shell
intro session; thanks to all the attendees for coming!

https://bugzilla.gnome.org/show_bug.cgi?id=609135
2010-02-08 14:04:45 -05:00
Maxim Ermilov
d9008054cf Handle resolution changes
Added signal 'screen-size-changed' to ShellGlobal.
Connect to this signal in main.js and run the _relayout() method.
If Overview or calendar are visible when this signal emit, they will be hiding.
https://bugzilla.gnome.org/show_bug.cgi?id=584526
2010-01-19 21:32:36 +03:00
Colin Walters
c17e1249d5 [panel] Scale up, center and fade application icon in app menu
Per 20091114 design.

https://bugzilla.gnome.org/show_bug.cgi?id=605491
2010-01-07 18:33:01 -05:00
Colin Walters
1d2dc09ede [panel] Port to CSS
With some tweaks from JP St. Pierre to center things in case we ever
have a larger panel.

https://bugzilla.gnome.org/show_bug.cgi?id=602131
2009-11-23 14:33:49 -05:00
Colin Walters
2f1ca7bf28 Remove ShellButtonBox, button.js; Use St.Clickable in panel.js
StClickable replaces ShellButtonBox.  Reduce the number of
button-like things by deleting button.js.

To do so, add CSS style for the actitivies button.

https://bugzilla.gnome.org/show_bug.cgi?id=602131
2009-11-23 14:33:49 -05:00
Dan Winship
b0cb8fb85a [Chrome] clean up APIs and remove workarounds
https://bugzilla.gnome.org/show_bug.cgi?id=597044
2009-11-23 13:49:18 -05:00
Dan Winship
985d707788 Port ShellStatusMenu to javascript
https://bugzilla.gnome.org/show_bug.cgi?id=601458
2009-11-13 14:21:31 -05:00
Colin Walters
7548f2d71e [ShellWindowTracker] Don't skip "uninteresting" windows for focus
For the purposes of determining which application is focused, don't
skip "uninteresting" windows.  The old get_focused_window code
was used for usage tracking, but here we want reliable application
association.

Also convert a .text= to .set_text that was missed with the last
patch.

https://bugzilla.gnome.org/show_bug.cgi?id=599206
2009-10-21 11:30:13 -04:00
Colin Walters
a336ed79ae [panel] Work around Clutter bug causing missing name
The .text property doesn't queue a resize, see:
http://bugzilla.openedhand.com/show_bug.cgi?id=1851
2009-10-20 16:52:57 -04:00
Colin Walters
e941e8088b Split ShellAppMonitor into ShellWindowTracker, ShellAppUsage
The two parts were mapping windows to applications, and
recording application usage statistics.  The latter part
(now called ShellAppUsage) is much more naturally built on top of
the former (now called ShellWindowTracker).

ShellWindowTracker retains the startup-notification handling.

ShellWindowTracker also gains a focus-app property, which is
what most things in the shell UI are interested in (instead of
window focus).

ShellAppSystem moves to exporting ShellApp from more of its
public API, rather than ShellAppInfo.  ShellAppSystem also
ensures that ShellApp instances are unique by holding
a hash on the ids.

ShellApp's private API is split off into a shell-app-private.h,
so shell-app.h can be included in shell-app-system.h.

Favorites handling is removed from ShellAppSystem, now inside
appFavorites.js.

Port all of the JavaScript for these changes.

https://bugzilla.gnome.org/show_bug.cgi?id=598646
2009-10-20 12:55:07 -04:00
Colin Walters
7f5c600133 Use a fixed ordering for well-known icons
Define the ordering for well-known icons; see
the page http://live.gnome.org/Features/StandardIconOrdering

https://bugzilla.gnome.org/show_bug.cgi?id=598313
2009-10-19 14:57:02 -04:00
Colin Walters
38c06ca837 Create ShellApp, rebase things on it
Previously, we had ShellAppInfo, which contains fundamental
information about an application, and methods on ShellAppMonitor
to retrieve "live" information like the window list.

AppIcon ended up being used as the "App" class which was painful
for various reasons; among them that we need to handle window
list changes, and some consumers weren't ready for that.

Clean things up a bit by introducing a new ShellApp class in C,
which currently wraps a ShellAppInfo.

AppIcon then is more like the display actor for a ShellApp.  Notably,
the ".windows" property moves out of it.  The altTab code which
won't handle dynamic changes instead is changed to maintain a
cached version.

ShellAppMonitor gains some more methods related to ShellApp now.

In the future, we might consider changing ShellApp to be a GInterface,
which could be implemented by ShellDesktopFileApp, ShellWindowApp.

Then we could axe ShellAppInfo from the "public" API and it would
return to being an internal loss mitigation layer for GMenu.

https://bugzilla.gnome.org/show_bug.cgi?id=598227
2009-10-14 14:37:34 -04:00
Marina Zhurakhinskaya
212d5c1954 Add missing files to POTFILES.in; add a translation hint
POTFILES.in was missing some files.

"Activities" is not easily translatable into some languages, e.g. Russian,
so suggest using the word for "Overview" instead.
2009-10-09 00:30:10 -04:00
Owen W. Taylor
4c6f770dea Fix positioning of the Calendar on multihead
Parens were in the wrong place, resulting in the calendar not
being properly centered on the primary monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=597078
2009-10-07 14:52:49 -04:00
Marina Zhurakhinskaya
53d0581377 Don't process the first click on Activities button for a timeout period after the hot corner was triggered
This avoids opening and closing the overview when the hot corner is triggered
and the activities button is clicked.
2009-10-06 16:58:30 -04:00
Adel Gadllah
9b05304c2d Use better fitting color for non ARGB tray icons
Currently we use 0xefefefff as a background color for non ARGB tray icons,
which looks out of place (i.e does not fit the panel's background gradient).

Change it to 0x0b0b0bff to fix that.

https://bugzilla.gnome.org/show_bug.cgi?id=597148
2009-10-04 10:02:37 +02:00
Owen W. Taylor
afb3b1e718 Fixes for Calendar widget
Miscellaneous fixes from review:

- Distribute calendar.js and the interactive test
- Make the pointless protection against leap seconds actually work
  by starting in the middle of the day so that forward/back always
  move a day.
- Use a variable instead of an inline '8' to know where to start
  when removing old day actors.
- Remove a stray comment from the test

https://bugzilla.gnome.org/show_bug.cgi?id=596432
2009-10-01 16:48:24 -04:00
Owen W. Taylor
04e28cd7c4 Add a calendar pop-down to the clock
js/ui/calendar.js: Generic calendar widget
tests/interactive/calendar.js: Basic test of the calendar

js/ui/panel.js: Add a pop-down from the clock that shows a
  calendar widget. The pop-down is not menu-like to allow the user to
  interact with an application while looking at the calendar.
gnome-shell.css: Add theming for calendar, calendar popup, and for
  buttons on the panel

https://bugzilla.gnome.org/show_bug.cgi?id=596432
2009-10-01 15:05:11 -04:00
Dan Winship
d8cabbee0b More global-ization 2009-09-11 17:23:42 -04:00
Colin Walters
37ee16b34d Use clutter_event_get_* instead of ShellGlobal
Before Clutter gained accessors for event information, we had
shell_global_ functions.  Now that Clutter has them, use them and
delete the ShellGlobal code.

http://bugzilla.gnome.org/show_bug.cgi?id=594561
2009-09-08 17:58:13 -04:00
Dan Winship
d0d79c5b3e Make "global" global.
Rather than doing "let global = Shell.Global.get()" everywhere we
need it, just create a global variable called "global".

http://bugzilla.gnome.org/show_bug.cgi?id=594546
2009-09-08 16:21:15 -04:00
Owen W. Taylor
5803aa7e65 Simplify Button class by using ShellButtonBox
Make Button class purely about adding visuals, and use ShellButtonBox
for behavior. API equivalences:

  shell.button => shell.actor [for consistency]

  staysPressed parameter to constructor => replaced by manually setting
   the 'active' property of button.actor as appropriate

  pressIn/release => button.actor.active = true/false

  enter-event/leave-event signals => button.actor notify::hover

Along the way, this fixes a bug with the user status menu where it was
not getting set to active because the button was getting a leave
(triggered by the menu popping up and grabbing the pointer) before for
button release, which disabled the staysPressed behavior.

Reported by Michael Meeks
http://bugzilla.gnome.org/show_bug.cgi?id=593471
2009-08-29 15:20:19 -04:00
Owen W. Taylor
943c5e2edc Improve comment about button-release-event handler
Improve the documentation about the button-release-event handler
we put on the status-menu button at Colin's suggestion.

http://bugzilla.gnome.org/show_bug.cgi?id=593362
2009-08-28 12:40:56 -04:00
Owen W. Taylor
1340413740 Fix hang when clicking on the user status menu in the overview
shell-global.[ch]: Add shell_global_display_is_grabbed() that
  uses the newly added meta_display_get_grab_op() to check
  for existing grabs.
shell-status-menu.[ch]: Add shell_status_menu_is_active() to
  check if the menu is popped up. Check for active grabs before
  popping the menu up. Use gtk_menu_popdown() rather than
  gtk_widget_hide(). Remove an excess gtk_widget_show() and
  some excess casts.
panel.js: Check whether the status menu is popped up after button
  release, and if it's not popped up, unhighlight the button.

Reported by Nuno Donato
http://bugzilla.gnome.org/show_bug.cgi?id=593362
2009-08-28 12:34:04 -04:00
William Jon McCann
14a7e310fc Make the gradient on the top panel the same as the "dash"
The previous top color was a bit too bright.
2009-08-28 11:47:19 -04:00
Colin Walters
ed7881d6c9 [AppMonitor] Handle window title changes causing mapping changes
For Firefox/OpenOffice, right now we have a workaround in the
code where we look at their "title" property.  However, we
weren't monitoring that property for changes, and I'm fairly
certain Firefox at least was mapping a window and then very
quickly changing its title after.  So we need to handle
dynamic changes.

Split out the wm_class mapping from the title hack.  It was
messy and weird to have the two mixed because they're not
at all related, and we're not trying to handle WM_CLASS changes
right now.

Explicitly connect to notify::title in the case where we had
a title fallback.  When a title changes, just treat it as
an add+remove.

In the Application Menu area in the panel, hook up to app-added
and app-removed so we get notification of the active app changing.
2009-08-27 02:22:25 -04:00
Marina Zhurakhinskaya
72b4d2a234 Make hotCorner a class variable
This fixes a bug where we were already using this._hotCorner
in _onHotCornerEnvironsLeft() and were incorrectly setting
this._hotCornerEntered to false when the hot corner was
re-entered from the environs.
2009-08-21 15:56:07 -04:00
Marina Zhurakhinskaya
30d3c1fe72 Use a larger area around the hot corner to decide if the user has left the hot corner
Using a larger area around the hot corner to decide if the user has left the
hot corner prevents triggering the hot corner multiple times due to an
accidental jitter.
2009-08-18 14:59:53 -04:00
Colin Walters
ca51a8c926 Add initial calls to Gettext
We don't have a lot of strings, and what ones we do have we've
been avoiding duplication.  This patch adds calls to _() i.e. gettext
for those strings we do have.
2009-08-14 09:32:15 -04:00
Colin Walters
f00500d3d5 Bug 591246 - Move towards shell-black02 mockup
Remove the last use of passing width into Dash by having the
Pane with the previews scaling dynamically and relying on
Clutter scaling.

If we only have one workspace, don't display a selection frame
for it.

Rework Dash into a searchArea and sectionArea, which get
explicitly sized by overlay.js.  We use the workspaces size
to choose the size of those dash areas.

Switch dash colors/boxes etc. to ones from shell-black02.

Add a gradient to the panel.

Add a magnifier.svg for use in search.
2009-08-12 16:07:05 -04:00
Marina Zhurakhinskaya
babb13f603 Remove unused button width and height arguments and specify button height explicitly
minWidth and minHeight arguments of the Button class were not used.

Panel buttons need their height to be explicitly specified as
PANEL_HEIGHT to take up full panel height. This fixes the problem with the
user not being able to click at the very top edge of the panel to activate
the button.
2009-08-11 18:16:33 -04:00
Colin Walters
74eac21870 Add application menu area to panel
This is a start at the "Active Appliction Item" component of the
shell design.  Currently we just show the currently focused
application.  When launching a new application, we show that as well.

The implementation here is not complete; basically when launching
we de-focus the active one, and the application well shows the
most recent startup sequence.

This kind of fails in the case of multiple sequences, and we
also don't correctly de-focus the current window in other
launch paths.
2009-08-11 13:09:41 -04:00
Colin Walters
e330c5ea17 panel: Switch to fully dynamic layout
There was lots of fixed positioning in the Panel; now it is completely
dynamic, and width/height is driven from main.js.  We still have a
global constant Panel.PANEL_HEIGHT, but this is a big step towards
eliminating it.

Also, this avoids overdraw in the "way too many tray icons" case.  The
clock will shift left.
2009-08-11 13:08:19 -04:00
Sander Dijkhuis
47af454115 Bug 591437 - Rename overlay.js to overview.js
Replace 'overlay' with the more descriptive name 'overview'
where the Activities Overview is meant. Call it Overview
(capitalized) in code comments.

The overlay-group and overlay-key provided by Mutter are not
affected, since they may be used for other components than
the Activities Overview.
2009-08-11 15:15:25 +02:00
Marina Zhurakhinskaya
00cc32d95a Ignore clicks on hot corner during transition
It's both intuitive to go to the corner of the screen
and click the activities button at the same time.

Both actions bring up the overlay,  but combined
they cancel each other out.  This commit makes
clicking the hot corner not cancel the act of
going to the hot corner.

Based on a patch from Ray Strode.
2009-08-10 14:19:07 -04:00
Marina Zhurakhinskaya
ccafa53bd6 Enable hot corner for triggering the overview mode
Use the 1x1 actor in the top left corner of the screen to enter and leave
the overview mode by just moving the mouse over to it.

No delay is used for triggering the hot corner because a delay significant
enough to allow moving away the mouse to avoid triggering it ruins the desired
flow when triggering the hot corner is actually intended.

The hot corner is not enabled in the full screen mode because the application
or the virtual system might have a hot corner of its own in that place.
2009-08-07 16:45:35 -04:00
Colin Walters
61b28c5c7d Adjust tray spacing to cope with many icons
This patch attempts to adjust if we have many tray icons; currently
the simple algorithm is to drop down to a spacing of 8 if we have
more than 6.  In the future we should fix the panel layout so that
the clock moves to the side.
2009-08-03 20:42:00 -04:00
Sander Dijkhuis
9e85d197fd Bug 588462 - Use a plain black panel with a different layout
The semi-transparent gradient on the panel is replaced by a
solid black background. The shadow below the panel is removed.
The clock is put at the center instead of the right side of
the panel and has the date removed. The user icon is hidden.
Instead of boldface, a regular font is used. Padding is added
on each side and between panel elements.

button.js: Allow for custom text colors and fonts.
panel.js: Change the panel colors and layout, remove the shadow.
2009-07-16 22:02:32 +02:00
Sander Dijkhuis
f7a82d6400 Bug 588445 - Use BigBox vertical alignment for the clock
panel.js: Replace the manual vertical padding calculation
    for the panel's clock with an y_align property on its
    BigBox container.
2009-07-13 16:16:44 +02:00
Sander Dijkhuis
10e30f7dc7 Bug 588405 - Handle status menu button appearance in JavaScript
Make the ClutterText and ClutterTexture from the status menu
button available to JavaScript, and from there improve the
font definition of the user name.

shell-status-menu.[ch]: Add public get_name() and get_icon()
    functions that return the user name label and icon
    texture, remove the markup from update_name_text().
panel.js: Set the font for the button consistently with that
    of the other panel labels.
2009-07-13 13:54:38 +02:00
Colin Walters
8ef48ca33c Animate panel appearance on startup 2009-07-02 01:04:40 -04:00
William Jon McCann
361461d1b9 Allow status icons to receive clicks at edge of screen
This removes the border and padding and aligns the box to the top.  Perhaps we
could push the padding down into the active area of the icon since it does look
a bit nicer with it.

http://bugzilla.gnome.org/show_bug.cgi?id=583139
2009-06-03 22:24:59 -04:00
Dan Winship
3ed0c2dc1c Take advantage of trayicon transparency in gtk+ 2.16
Fall back to the old behavior with older gtk.

http://bugzilla.gnome.org/show_bug.cgi?id=582484
2009-06-02 10:36:07 -04:00
Dan Winship
bc558306a4 Improve the framework for managing shell UI
Adds an explicit "chrome" layer for the panel (and later the sidebar),
managing the input region and struts for them, and hiding them when
fullscreen windows are present or the user enters the overlay.

http://bugzilla.gnome.org/show_bug.cgi?id=581771
2009-05-15 16:12:53 -04:00