Commit Graph

187 Commits

Author SHA1 Message Date
Sardem FF7
8f3376ce62 Add "precision" to boxpointer alignment
Allows the boxpointer arrow to be at a fixed percentage of the bubble

https://bugzilla.gnome.org/show_bug.cgi?id=642031
2011-02-16 10:19:39 -05:00
Adel Gadllah
c2ae95f912 AppWellMenu: Remove window filtering
Don't filter and highlight windows when opening the menu
as this turned out to be distracting and confusing.

https://bugzilla.gnome.org/show_bug.cgi?id=642189
2011-02-14 23:07:27 +01:00
Florian Müllner
b0efe684fc app-icon: Use the dash's icon size for dragged icons
As the dash is one of the primary drop targets for dragging application
launchers, it's reasonable to use the dash icon size for app icons'
drag actors, especially with the larger size now used in the application
view.

https://bugzilla.gnome.org/show_bug.cgi?id=639428
2011-02-12 23:32:57 +01:00
Florian Müllner
8f7d5cde90 app-display: Only reset filters when they have been initialized
The view might get mapped before the filters have been added, so
trying to reset to the "All" filter will throw an exception. Fix
by only do the reset if the filters have been initialized.
2011-02-10 16:34:23 +01:00
Florian Müllner
d90c98130e app-display: Always select "All" filter on switch
When switching to the app view, it is unlikely that a user is
going to select an application from the same filter list as the
last time the view was used, so reset the view to the "All" filter
on switch.

https://bugzilla.gnome.org/show_bug.cgi?id=641987
2011-02-10 01:23:01 +01:00
Florian Müllner
af3883905b app-view: Reset scroll position on switch
When switching to the application view, the view is still scrolled
to the position it had when left previously. Given that it is rather
unlikely that the application the user wants to select is located close
to that position, it appears beneficial to start at a predictable
position, so make sure that the scroll position is always reset to
the top.

https://bugzilla.gnome.org/show_bug.cgi?id=641987
2011-02-10 01:23:01 +01:00
Owen W. Taylor
0d32017ffc Don't switch to a workspace when dragging it to launch on that workspace
With workspace thumbnails, we don't switch workspaces when dragging windows
between workspaces or adding new workspaces, so we also shouldn't switch
on launch.

 * Add workspace parameters to shell_doc_system_open(),
   shell_app_activate, shell_app_open_new_window()

 * Pass a 'params' object when activating items in the overview with
   two currently defined parameters: workspace and timestamp. (timestamp
   is only implemented where it is easy and doesn't require interface
   changes - using the global current timestamp for the shell is almost
   always right or at least good enough.)

https://bugzilla.gnome.org/show_bug.cgi?id=640996
2011-02-08 19:43:21 -05:00
Owen W. Taylor
f038ce1c69 Remove now unnecessary workspace controls
With automatic workspace management, explicit controls to add and
remove workspaces are no longer necessary. We also can remove the
use of addWorkspace for middle-button-click on a launcher since
launching on the last empty workspace will do the right thing.

https://bugzilla.gnome.org/show_bug.cgi?id=640996
2011-02-08 19:43:20 -05:00
Owen W. Taylor
3c593fc056 Don't check for Workspaces.WindowClone for window drops
When checking the type of a DND source, instead of checking
'instanceof Workspaces.WindowClone' accept any actor with realWindow
and metaWindow properties. This will be useful to support a separate
type of actor dragged from workspace thumbnails.

https://bugzilla.gnome.org/show_bug.cgi?id=640996
2011-02-08 19:43:20 -05:00
Dan Winship
c86a977564 St: drop StClickable, add some functionality to StButton
For historical reasons, we had both StClickable and StButton, which
were nearly identical. StButton was more widely-used, so keep that and
port all StClickable users to that.

https://bugzilla.gnome.org/show_bug.cgi?id=640583
2011-02-07 12:45:48 -05:00
Dan Winship
c256fa9b9f AppIcon: right-click menu should appear on press, not click
https://bugzilla.gnome.org/show_bug.cgi?id=640583
2011-02-07 12:45:48 -05:00
Florian Müllner
e96a90b161 app-display: Enable swipe-scrolling in the app view
With general support for swipe-scrolling in the overview, there is
no reason to limit the behavior to workspaces. It is equally useful
for scrolling through the grid of available applications, so enable
swipe-scrolling for the app view.

https://bugzilla.gnome.org/show_bug.cgi?id=635034
2011-01-24 02:59:46 +01:00
Adel Gadllah
00ba937171 StScrollView: Implement real fade effect
Implement an edge fade effect (top/bottom) using a
ClutterOffscreenEffect subclass, replacing the former
shadow hack.

https://bugzilla.gnome.org/show_bug.cgi?id=639460
2011-01-20 20:53:20 +01:00
Florian Müllner
38fb51a99e app-display: Expose BaseIcon params in AppWellIcon
AppWellIcon is used both in the dash and view selector. As the dash
requires manual sizing, it is not possible to set the icon size used
in the view selector in the CSS, but icons will use the default size
(unless set manually as in the dash).

Expose the params parameter of BaseIcon and enable manual resizing
only for AppWellIcons in the dash.

https://bugzilla.gnome.org/show_bug.cgi?id=639428
2011-01-13 18:27:23 +01:00
Florian Müllner
52a87a22ec appDisplay: Add translator comment for "All" filter
The correct translation for "All" depends on context in some
languages, so add a translator comment.

https://bugzilla.gnome.org/show_bug.cgi?id=637559
2010-12-21 20:10:16 +01:00
Maxim Ermilov
4fd24da4e4 app-display: Implement filtering applications by category
Add a list of filters to the application view of the view selector, as in the latest mockups

https://bugzilla.gnome.org/show_bug.cgi?id=631537
2010-12-18 22:23:33 +03:00
Florian Müllner
08b84b1449 app-display: Popup menus to the left in RTL locales
The popup menus of application icons in both the dash and the app view
are positioned on the right of the icon. In the case of the dash this
results in the menu being displayed off-screen in RTL locales, so move it
to the opposite side instead.

https://bugzilla.gnome.org/show_bug.cgi?id=635645
2010-12-01 00:02:16 +01:00
William Jon McCann
c908a060b8 Touch up the spacing and style of the app view
Adds more padding between app icons, left aligns the view,
removes the ugly separator, adds some margin on the right.
2010-11-29 13:16:20 -05:00
Florian Müllner
2c5d825c87 search-display: Change the default display to use iconGrid
Current mockups display all search results as icons as used by
application results, so change the default result display to use
iconGrid/BaseIcon. Remove the custom application results display,
as it is no longer needed.

https://bugzilla.gnome.org/show_bug.cgi?id=634948
2010-11-29 16:35:53 +01:00
Florian Müllner
1eb6dfe1b8 app-display: Slight cleanup and style update
Being no longer an independent menu pane, both the toggle() and
close() functions are no longer needed, and the view's structure
can be simplified a bit.

Also update the style to fit into the view selector.

https://bugzilla.gnome.org/show_bug.cgi?id=634948
2010-11-29 16:35:53 +01:00
Florian Müllner
3e4f744e56 dash: Reimplement the dash based on AppWell code
The new dash implementation is a single-column vertical sidebar,
whose items are scaled dynamically to fit the available height.
If the height is still exceeded after scaling down to a minimum
item size, excess items are cut off.
The now unused old dash implementation is renamed to OldDash, as
its code will be used as a base for the new view selector element.

https://bugzilla.gnome.org/show_bug.cgi?id=634948
2010-11-29 16:35:47 +01:00
Dan Winship
548a23a969 PopupMenu: redo keynav using St.FocusManager
Each menu is a focus manager group, but there is also some explicit
focus handling between non-hierarchically-related widgets. Eg, to move
between menus, or from a menubutton into its menu.

https://bugzilla.gnome.org/show_bug.cgi?id=621671
2010-10-29 08:38:05 -04: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
Florian Müllner
1bd0ad11d8 Use WellGrid for application results
Extend WellGrid with an optional rowLimit parameter and an accessor
function for the grid's items, then use it to replace the custom
container used to display the application search results.
Also adjust the spacing of the search results slightly to make it
consistent with the app well.

https://bugzilla.gnome.org/show_bug.cgi?id=622446
2010-09-15 00:18:22 +02:00
Maxim Ermilov
38c3422331 [DND] change cursor when dragging
Return a DND.DragMotionResult constant from delegate _handleDragMotion
methods as well as the existing return value from the drag monitor method dragMotion.
https://bugzilla.gnome.org/show_bug.cgi?id=607821
2010-09-10 06:00:28 +04:00
Florian Müllner
4632db177a Clean up unused includes
Some late spring cleaning ...
2010-07-19 01:46:01 +02:00
Giovanni Campagna
97f883b10e Implement "text-align"
"text-align" allows setting the alignment of text, with respect to
other lines and allocated space, without requiring a reference to
the ClutterText (which is private for most widgets).
If not specified, all text is left-aligned.

https://bugzilla.gnome.org/show_bug.cgi?id=622447
2010-06-25 22:43:14 +02:00
Dan Winship
748739ed9c [appDisplay] port from ShellMenu to PopupMenu
This fixes the style, and also makes it keyboard navigable

https://bugzilla.gnome.org/show_bug.cgi?id=619541
2010-06-10 15:04:48 -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
88be8e87ac [Overview] Fade dash menus
As the design calls for smooth transitions whenever possible, use
a similar fade effect for the all-apps and more-docs menus as for
the panel menus.

https://bugzilla.gnome.org/show_bug.cgi?id=620775
2010-06-09 17:07:10 +02:00
Maxim Ermilov
b83d5975b0 [appDisplay] Fix crash when app well is empty
When the app well doesn't contain any applications, it displays a placeholder text
to indicate that it's a drop target. When porting WellGrid from St.Bin to St.BoxLayout,
the call to set_child() to set the text was overlooked.
https://bugzilla.gnome.org/show_bug.cgi?id=617281
2010-06-09 17:41:09 +04:00
Florian Müllner
87e5457095 [dash] Right align well icons for RTL locales
When changing the alignment of well icons from centered to left,
we should swap it for RTL locales.

https://bugzilla.gnome.org/show_bug.cgi?id=619236
2010-06-08 23:51:16 +02:00
Florian Müllner
cba49959c1 [dash] Left align well items
When the app well does not contain enough items to fill a single
row, items are centered - the same applies to sections in the
all-app menu.

https://bugzilla.gnome.org/show_bug.cgi?id=619236
2010-06-08 23:10:06 +02:00
Florian Müllner
dad80b3d20 [appWellIcon] Set correct style in constructor
Currently, only the base style class is set in the constructor, the
style update according to the state of the represented app is deferred
until the actor is shown.

As existing icons are destroyed and recreated when the number of icons
changes, this behavior causes the icons of running apps to flicker if
CSS transitions are used.

Set the style directly in the constructor and update the code to not
delay style updates until the actor is shown - StWidget does defer
expensive calculations until the actor is mapped anyway.

https://bugzilla.gnome.org/show_bug.cgi?id=620782
2010-06-08 20:47:39 +02:00
Maxim Ermilov
3d60245b18 Add sections to the all apps view
Separate out the main app view into different sections based on the categories
in the desktop file. The configuration is done via gmenu and the desktop menu
specification, we set XDG_MENU_PREFIX="gs-" on startup, so that gmenu reads
gs-applications.menu, which we install.

There is no support for "submenus" - only the menus directly under
Applications will be displayed as categories.
https://bugzilla.gnome.org/show_bug.cgi?id=614131
2010-06-06 02:53:27 +04:00
Florian Müllner
a57a34c540 [linearView] Zoom out when dragging an item from the dash
When dragging windows in linear view, the workspace zooms out to
allow moving the window to other workspaces. Enable the same
behaviour for items dragged from the dash.

https://bugzilla.gnome.org/show_bug.cgi?id=618055
2010-05-27 12:12:10 +02: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
Marina Zhurakhinskaya
4ce2620b68 Don't add a new workspace when the maximum workspaces limit is reached
It was previously possible to add a workspace above the maximum workspaces
limit by dragging an item to the "add workspace" button or using the middle
mouse button click.

Provide the user with feedback in the info bar when it is not possible to create
a new workspace or remove the current workspace.

https://bugzilla.gnome.org/show_bug.cgi?id=591645
2010-05-13 14:30:52 -04:00
Marina Zhurakhinskaya
ec6bc8f216 Make the workspace added on the middle mouse button click active
This ensures that we launch the new instance of an application on the newly
added workspace in the grid view, in which we don't make the newly added
workspace active by default.

https://bugzilla.gnome.org/show_bug.cgi?id=591645
2010-05-13 14:30:52 -04:00
Christina Boumpouka
21ff050a40 Add a new way to open an application on a new workspace
Allow using the middle mouse button to open a new instance of an
application on a new workspace. The middle mouse button function
can be achieved by clicking the left and right mouse buttons
together with a two buttons mouse or holding Ctrl while clicking
with a single button mouse.

https://bugzilla.gnome.org/show_bug.cgi?id=591645
2010-05-12 20:30:00 +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
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
Dan Winship
46c210c314 [ShellMenu] port from BigBox to StBoxLayout
The actual changes to shell-menu.[ch] are pretty minimal; most of the
changes there are just style/spacing/indentation.

Also, removed shell_menu_append_separator() since it wasn't needed;
the separators would already have been behaving as intended just
because they were non-reactive.

https://bugzilla.gnome.org/show_bug.cgi?id=614516
2010-04-06 08:25:34 -04:00
Dan Winship
b4c3ab6726 [StDrawingArea] further CSS-ify StDrawingArea users
Make shell_draw_box_pointer() use CSS colors, and set the app well
menu arrow width based on its own CSS rather than its parent's.

https://bugzilla.gnome.org/show_bug.cgi?id=614516
2010-04-06 08:22:10 -04:00
Dan Winship
045faf3f12 Fix appIcon menu arrows
We were looking up the wrong property for the width, and then only
setting the foreground color if a void function returned TRUE.

https://bugzilla.gnome.org/show_bug.cgi?id=614516
2010-04-06 08:17:32 -04:00
Florian Müllner
feaaefd8ba [appDisplay,placeDisplay] Remove manual dnd mode
As the special handling for St.Clickable moved into dnd, it is no
longer necessary to use manual mode in these cases.

https://bugzilla.gnome.org/show_bug.cgi?id=610385
2010-03-29 17:46:05 +02:00
Florian Müllner
d9f43e27a0 [AppDisplay] Popup the menu on left-click/hold
Left-clicking an app icon and holding the button used to pop up the
app menu, but regressed when rewriting appDisplay.
Restore the previous behavior.

https://bugzilla.gnome.org/show_bug.cgi?id=609013
2010-03-24 19:38:59 +01:00
Dan Winship
a8fa8a498a Fix dragging of App Well and Places icons
The hover rewrite added a freeze/thaw_notify to
st_clickable_leave_event() (to match the one already in
st_clickable_enter_event()), which broke code in two places that
assumed "pressed" would still be TRUE when "hover" changed to FALSE.
Fix that by exposing the "held" property as well.
2010-03-24 13:48:29 -04:00
Dan Winship
f9e4385e02 [StWidget] add (optional) hover tracking
If track-hover is set, update the hover property automatically, and
the "hover" pseudo class to match, as StClickable used to do. (Remove
the corresponding code in StClickable). Tweak the tooltip handling to
use track-hover, which also makes it slightly more reliable in the
presence of reactive children, etc.
2010-03-24 10:03:50 -04:00