Commit Graph

1236 Commits

Author SHA1 Message Date
Adel Gadllah
e6b80927ad Fix demands attention to work with new messagetray api 2010-02-22 23:43:02 +01:00
Florian Müllner
f9c5202dd1 Always make notifications with '\n' in bannerText expandable
Right now notifications are expandable if the length of bannerText
exceeds the notification's width - however, if bannerText contains
newlines, it should be expandable regardless of the length.

https://bugzilla.gnome.org/show_bug.cgi?id=610549
2010-02-22 23:41:09 +01:00
Florian Müllner
a21ba292eb Cancel zoom of non-focused windows when leaving overview
When leaving the overview by hitting escape or super, all windows animate
to their original positions. Zoomed windows are kept above others until
the animation ends, then the focused window is brought to the front; as
this looks odd if the zoomed window does not have focus, cancel the zoom
in that case before leaving the overview.

https://bugzilla.gnome.org/show_bug.cgi?id=609243
2010-02-22 23:41:09 +01:00
Florian Müllner
5429104f04 Fix problems when leaving the overview with a zoomed window
While zooming, a window clone is reparented to the stage and thus cannot
be destroyed automatically by the "parent" container. To prevent the clone
and the corresponding overlay from leaking, we enforce destroying the clone
with the workspace.

https://bugzilla.gnome.org/show_bug.cgi?id=609243
2010-02-22 23:41:09 +01:00
Marina Zhurakhinskaya
bb0a977edc Special-handle Empathy to have multiple sources and to queue notifications
We are planning to add Empathy-specific features in the message tray, but in the
meantime we handle Empathy notifications received through the notification daemon
so that their behavior is closer to the eventual design, which is how it was before
we started associating applications with a single source and enabled notification
replacement.
2010-02-22 17:27:23 -05:00
Marina Zhurakhinskaya
77ed621c74 Associate sources with applications
Use the "appName" parameter in notifications to identify the source
rather than the id - use the latter to enable update and removal of
individual notifications as laid out in the desktop notification spec.

This is a rebase of the patch by Florian Müllner.
2010-02-22 17:21:00 -05:00
Maxim Ermilov
fc39919856 Add top and bottom shadows to app browser
Add a 'vshadow' property to StScrollView, which, when turned on,
overlays gradient shadows on the top and bottom of the StScrollView.

Turn this on for the StScrollView used for the app browser.
https://bugzilla.gnome.org/show_bug.cgi?id=609604
2010-02-23 01:12:13 +03:00
Dan Winship
d8800c095a NotificationDaemon: add rewriteRules infrastructure, use it for xchat
Changes notifications like:

    XChat: Private message from: danw (GimpNet) blah...

to

    danw: blah blah blah blah

(the "XChat" being unnecessary since there's already an xchat icon
there anyway.)

https://bugzilla.gnome.org/show_bug.cgi?id=608915
2010-02-22 17:09:13 -05:00
Dan Winship
e5ba414f2d Add the workspaces view key to the gconf schema
Also rename the key to make it less ambiguous, and change its value
from an int to a string.

https://bugzilla.gnome.org/show_bug.cgi?id=609871
2010-02-22 17:01:47 -05:00
Mads Villadsen
b8a9eec14f Make width of workspace switcher popup dynamic
Make the width of the workspace switcher dynamic in order to make it have the same proportions as the actual screen.

Call redraw after adding indicator to stage to avoid warning.

https://bugzilla.gnome.org/show_bug.cgi?id=610049

Signed-off-by: Adel Gadllah <adel.gadllah@gmail.com>
2010-02-22 20:29:49 +01:00
Adel Gadllah
059504ca70 Add demands attention support to the messagetray
Inform the user about demands attention events using the messagetray.

Clicking on the notification icon moves the user to the window.

It differentiates between newly started apps and windows of already running apps, by showing different banners for this cases.

It is based on Jon Nettleton's "window attention" extension.

https://bugzilla.gnome.org/show_bug.cgi?id=610594
2010-02-22 20:09:43 +01:00
Florian Müllner
b2db95380b [MessageTray] Clear bannerText before re-adding on updates
Currently only the old title/summary line is removed from
notifications before setting the updated values - do the
same for bannerText if applicable.
2010-02-22 20:14:44 +01:00
Florian Müllner
b6bb26e9ae Add additional padding to the view specific workspace controls
In the latest mockup, there is more spacing around the scroll bar than
between the other controls.

https://bugzilla.gnome.org/show_bug.cgi?id=610189
2010-02-22 18:47:04 +01:00
Florian Müllner
126d02ae90 Fix invalid call to st_widget_get_theme_node() in WindowOverlay
WindowOverlay has two actors, both with custom style properties, which
share a common _onStyleChanged() handler. This is not a problem when
entering the overview, because the actors' parent (the workspaces group)
is hidden while the actors are added. However, when windows are added to
the workspace while in the overview (e.g. when opening a new window or
dragging a window from one workspace to another), adding the first actor
to the workspaces group triggers a style-changed signal - the handler
then calls st_widget_get_theme_node() on both actors, which triggers a
warning as the second actor has not been parented yet.

https://bugzilla.gnome.org/show_bug.cgi?id=610279
2010-02-22 18:33:58 +01:00
Maxim Ermilov
8d76e362a0 _computeWindowMotion calculate difference between relative positions
https://bugzilla.gnome.org/show_bug.cgi?id=607826
2010-02-22 20:14:13 +03:00
Colin Walters
004cf3da5c [appDisplay] Use AUTOMATIC for apps-more, not ALWAYS
No need to display a scrollbar if we don't need to, and ALWAYS
isn't yet implemented anyways.

https://bugzilla.gnome.org/show_bug.cgi?id=609015
2010-02-22 12:07:23 -05:00
Colin Walters
fb9fd6925a [StScrollView] Fix incorrect assertion, defaults, and test case
The type we don't currently handle is _ALWAYS, my original use
of g_return_if_fail was wrong.

Also the default should be AUTOMATIC in the properties, not ALWAYS.

Finally the test case was still using the incorrect St.ScrollPolicy.

https://bugzilla.gnome.org/show_bug.cgi?id=609015
2010-02-22 12:06:56 -05:00
Florian Müllner
ec725cc6d4 [Notification] Replace all newlines in body with spaces
Accidentally we only replaced the first newline of the body text with
spaces - replace all occurrences instead.

https://bugzilla.gnome.org/show_bug.cgi?id=610549
2010-02-21 03:54:13 +01:00
Florian Müllner
79fe60e6fb [messageTray] Fix text with ampersands not being displayed
If the notification body contains '&' it ends up empty and a warning
about an invalid entity is printed on stderr, so our escape code must
handle ampersands as well.

https://bugzilla.gnome.org/show_bug.cgi?id=607375
2010-02-21 03:54:06 +01:00
Maxim Ermilov
c793d7d0a4 get_app_for_window_direct search ShellApp by window, before create.
https://bugzilla.gnome.org/show_bug.cgi?id=610324
2010-02-21 03:19:24 +03:00
Florian Müllner
1b7c3580e6 Show/hide the summary during the overview transition
Right now, the summary starts popping up when the overview has been
shown and starts to disappear when the overview is hidden. Instead,
animate the summary during the overview transition.

https://bugzilla.gnome.org/show_bug.cgi?id=610520
2010-02-20 20:05:50 +01:00
Ivaylo Valkov
3c3e0b6f20 Updated Bulgarian translation 2010-02-20 14:30:00 +02:00
Colin Walters
fd6863dda4 Add missing section-more-open file from previous commit 2010-02-19 15:52:56 -05:00
Maxim Ermilov
690be611ee Implement newer design for "more apps" view
Replace the old GenericDisplay-based system with one which reuses
the WellGrid class and uses a new scrolling container.

https://bugzilla.gnome.org/show_bug.cgi?id=609015
2010-02-19 15:39:26 -05:00
Colin Walters
18c5405b79 [StScrollView] Add support for GtkPolicyType for scrollbars
Previously we were hacking out the vertical scrollbar, this patch
allow us to sanely say in which directions we want to scroll.

Note this patch intentionally changes St to depend on GTK+ in the
API.  I believe this is a correct long term change where we should
view St as co-evolving with GTK+ rather than replacing or paralleling.

https://bugzilla.gnome.org/show_bug.cgi?id=609015
2010-02-19 15:37:40 -05:00
Maxim Ermilov
cfd63c7d4c fix selection of all-workspace windows
all-workspace windows can be active on every workspace.
https://bugzilla.gnome.org/show_bug.cgi?id=603078
2010-02-19 21:29:46 +03:00
Maxim Ermilov
49a9335f68 fix sizing of all-workspace windows in the overview
Window can have more then one clones on different workspaces.
https://bugzilla.gnome.org/show_bug.cgi?id=603078
2010-02-19 21:29:35 +03:00
Maxim Ermilov
5b1d52c5e7 Fix build problem with mutter 2.29
Query mutter's version more or equal 2.29.0
2010-02-19 20:54:47 +03:00
Florian Müllner
9f43ed3f95 Use _onDestroy() handlers for cleanup in delegates
Unify the style of <delegate>.destroy() methods to only contain a
call to <delegate>.actor.destroy() and handle additional cleanup
in a _onDestroy() signal handler.

https://bugzilla.gnome.org/show_bug.cgi?id=609454
2010-02-18 22:50:34 +01:00
Florian Müllner
0770fd5be5 Use St.Button for preview close buttons
Originally, we used St.Bin for the preview close buttons - using
St.Button instead adds support for pseudo classes to style different
button states.
2010-02-18 19:25:28 +01:00
Florian Müllner
3c8ba348c2 Slide out removed workspaces in linear view
Instead of deleting workspaces immediately, animate the removal - it may
be useless eye-candy, but it's pretty sexy nonetheless ...
More seriously, the animation improves consistency with both workspace
additions and the mosaic view.

https://bugzilla.gnome.org/show_bug.cgi?id=609673
2010-02-17 23:37:05 +01:00
Florian Müllner
b84a7042f1 Make spacing between workspaces stylable
Currently the width of the gaps between workspaces in both linear
and mosaic view are defined as constants. Move these to the theme's
CSS instead.

https://bugzilla.gnome.org/show_bug.cgi?id=609673
2010-02-17 23:37:05 +01:00
Florian Müllner
8ef75524ea [Workspaces] Clean up scrolling in linear view
Reorganize the code to break up positioning into:

1) updating workspace object's scale and position
2) applying the updated parameters to the workspace actor
3) scrolling the view to a particular workspace
4) handling dragging of the scroll bar

With these cleanups, it becomes much easier to fix
the following issues:

- use animations consistantly instead of doing hard breaks
  for some actions and smooth transitions for others
- snap to the closest workspace when scrolling stops
  (https://bugzilla.gnome.org/show_bug.cgi?id=607823)
- fix the regression of the zoomFromOverlay animation when
  the selected app is on another workspace
  (https://bugzilla.gnome.org/show_bug.cgi?id=609081)

https://bugzilla.gnome.org/show_bug.cgi?id=609673
2010-02-17 23:36:58 +01:00
Dan Winship
cec62a7ca5 Main.activateWindow: always exit the overview if it's currently open
This way, clicking a message tray icon while the overview is open will
close the overview when activating its window.

Remove some other overview-related activation code which is now
redundant.

Also, remove calls to "global.get_current_time()" when calling
Main.activateWindow, since it's unnecessary (activateWindow will call
it itself if you don't pass in that arg).

https://bugzilla.gnome.org/show_bug.cgi?id=609765
2010-02-17 17:08:28 -05:00
Dan Winship
77fe0db623 [MessageTray] Show the message tray in the overview
Also, make the summary area always visible when in the overview

https://bugzilla.gnome.org/show_bug.cgi?id=609765
2010-02-17 17:08:24 -05:00
Dan Winship
e86c821878 [MessageTray] reimplement the state machine
Previously, every time _updateState was called, it would make some
change, and so it was necessary to very carefully set up all the calls
to it, to ensure it was always called at exactly the right time. Now,
instead, we keep a bunch of state variables like "_notificationState"
and "_pointerInSummary", and potentially multiple timeouts, and
_updateState looks at all of them and figure out what, if anything,
needs to be changed.

By making the rules about what causes changes more explicit, it will
be easier to change those rules in the future as we add new
functionality.

Also, update the rules a bit, so that notifications can appear while
the summary is visible, and the summary only shows after a
notification if the summary has changed.

https://bugzilla.gnome.org/show_bug.cgi?id=609765
2010-02-17 17:06:17 -05:00
Dan Winship
02f67af464 [MessageTray] Fix summary to be initially-hidden
Some recent change broke it so that the first time a notification pops
up, the summary will be visible alongside it.

https://bugzilla.gnome.org/show_bug.cgi?id=609765
2010-02-17 14:45:59 -05:00
Maxim Ermilov
fd310bc7b9 Correct position of window previews.
align the bottoms of the window previews.
window previews always fit in the slot.
https://bugzilla.gnome.org/show_bug.cgi?id=610070
2010-02-17 19:56:45 +03:00
Florian Müllner
94d3e27c53 [Overview] Fix tiled background images
Tiled backgrounds are only displayed once in the upper left corner when
in the overview - they should be tiled just like outside the overview.

https://bugzilla.gnome.org/show_bug.cgi?id=610203
2010-02-17 17:34:38 +01:00
Adel Gadllah
6aa02c5edc [AppSwitcher] Make sure that fallback icons have correct box sizes
Fallback icons (i.e icons < requested size) cause the box in the switcher
to be a smaller rectangular item instead of the normal sized square one.

Fix that by putting the icons in a St.Bin with the correct size.

https://bugzilla.gnome.org/show_bug.cgi?id=609777
2010-02-17 10:52:11 +01:00
Florian Müllner
97e19d7d4a Adjust behavior of search results to match app well
Currently, activating a search result always opens a new window. Change
this behavior, so that if an application has open windows, the most
recently used one is activated instead.

Also change the implementation of dnd of search results to allow providers
to treat results activated via dnd differently.

https://bugzilla.gnome.org/show_bug.cgi?id=610027
2010-02-16 23:50:35 +01:00
Dan Winship
94f32030e6 [MessageTray] notification size/wrapping fixes
Make the font match the panel.
Make the max width be em-based rather than screen-size-based.
Fix it to break lines mid-word if needed.

https://bugzilla.gnome.org/show_bug.cgi?id=606755
2010-02-16 14:08:17 -05:00
Dan Winship
721e1ea863 [St] Implement max-width/max-height in the CSS parser
st_theme_node_adjust_preferred_width/height now limit the content area
of an actor to the max, if given. (The requested width/height may be
larger to make room for borders, etc.)

https://bugzilla.gnome.org/show_bug.cgi?id=606755
2010-02-16 14:08:17 -05:00
Dan Winship
5331d3e360 [St] Make allocation handling more consistent
In StBin, StBoxLayout, and StTable, if a child has a potential
allocation that is larger than its preferred size, we give it its
preferred size instead. However, the corresponding
get_preferred_height/width methods were not making the same
assumption, which meant that if we had more width than the widget
wanted, we would allocate it its preferred width, but with the height
that corresponded to the larger width.

Fix this by defining new helpers _st_actor_get_preferred_width() and
_st_actor_get_preferred_height() and using them everywhere. Also, make
StBin and StTable use _st_allocate_fill() rather than having
nearly-identical duplicate copies of the code.

https://bugzilla.gnome.org/show_bug.cgi?id=609848
2010-02-16 14:06:39 -05:00
Dan Winship
f52744cfbc [StTable] fix x-align/y-align properties to be StAlign, not double
This puts it in sync with StBin and StBoxLayout

https://bugzilla.gnome.org/show_bug.cgi?id=609848
2010-02-16 14:06:39 -05:00
Adel Gadllah
4749393ab5 Remove panel-run-dialog/main-menu handling from shell-global
This is handled by the shellwm (takeover_keybinding) nowdays.

https://bugzilla.gnome.org/show_bug.cgi?id=610039
2010-02-16 16:50:40 +01:00
Nguyễn Thái Ngọc Duy
975603d608 Updated Vietnamese translation 2010-02-16 19:36:49 +07:00
Gabor Kelemen
99346522e9 Hungarian translation updated 2010-02-16 10:10:45 +01:00
Dan Winship
090335ad8b [MessageTray] fix notifications with short banners and action buttons
Previously the banner was only promoted to the body if it got
truncated, but the banner was *always* hidden when expanding the
notification. This meant a message with a short banner, plus
notification buttons, would have no banner text visible when it was
expanded. Fix that.

https://bugzilla.gnome.org/show_bug.cgi?id=606755
2010-02-15 17:28:23 -05:00
Florian Müllner
d8af8f7305 [CSS] Update overview style to match latest mockup
https://bugzilla.gnome.org/show_bug.cgi?id=609401
2010-02-15 22:14:31 +01:00