Commit Graph

1612 Commits

Author SHA1 Message Date
Jorge González
25eaf2a294 Updated Spanish translation 2010-05-25 18:31:50 +02:00
Colin Walters
7bf748c579 [StTable] Align children to integral positions
Like the other St widgets, ensure we position children at integrals.

https://bugzilla.gnome.org/show_bug.cgi?id=619623
2010-05-25 11:21:34 -04:00
Colin Walters
04f33e8dc7 [StTable] Clamp children to integral positions 2010-05-25 11:00:50 -04: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
Frédéric Péters
f1e3104128 Do not fail if json Python module is not available
Fallback to old simplejson module if present, and options that require
the json module (create extension and performance) if absent.

https://bugzilla.gnome.org/show_bug.cgi?id=619580
2010-05-25 16:32:56 +02:00
A S Alam
2ace472100 updating for punjabi 2010-05-25 19:32:44 +05:30
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
Adel Gadllah
a1bfaac5a2 [appSwitcher] Remove unneeded workaround
SwitcherList.actor is no longer a St.BoxLayout but a
GenericContainer now, so the hack in AppSwitcher._getPreferredHeight is no
longer needed (it is called with the correct width now).

https://bugzilla.gnome.org/show_bug.cgi?id=613194
2010-05-24 16:52:38 +02:00
Kjartan Maraas
d80c1af1a3 Updated Norwegian bokmål translation 2010-05-24 16:29:32 +02:00
Owen W. Taylor
cbde065a01 [perf] Fix factor of ten in seconds => microseconds conversion
Typo: 10000000 instead of 1000000 for a million. Also, use
G_INT64_CONSTANT instead of LL for a 64-bit constant, to avoid
extraneous 128-bit arithmetic on 64-bit machines.
2010-05-24 00:09:40 -04:00
Rico Tzschichholz
0b1c7320ab Fix "make distcheck" - add missing reference for scripting.js - properly add js/perf/*
https://bugzilla.gnome.org/show_bug.cgi?id=619276
2010-05-22 18:02:52 +02:00
Adel Gadllah
ce3f003e46 Call shell_global_maybe_gc() when no work is being done
Call shell_global_maybe_gc when idle when no other work is ongoing to free
up memory and improve performance by preventing the GC to kick in at less
convenient times.

See: https://developer.mozilla.org/en/SpiderMonkey/JSAPI_Reference/JS_MaybeGC

https://bugzilla.gnome.org/show_bug.cgi?id=614725
2010-05-21 23:47:41 +02:00
Adel Gadllah
9fca747ef4 shell-global: Add shell_global_maybe_gc
Add a method to call JS_MaybeGC, see
https://developer.mozilla.org/en/SpiderMonkey/JSAPI_Reference/JS_MaybeGC

https://bugzilla.gnome.org/show_bug.cgi?id=614725
2010-05-21 23:47:25 +02:00
Matej Urbančič
9455554453 Updated Slovenian translation 2010-05-21 20:03:38 +02:00
Owen W. Taylor
4859eb63c4 [perf] Add --perf-upload option to gnome-shell
Add a command line option to upload the generated performance report
to a web service. The options for the upload (url, system name, secret
key) are read from ~/.config/gnome-shell/perf.ini.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 12:34:22 -04:00
Owen W. Taylor
e7220591ba [perf] Include monitor layout in performance reports
Add extra key, 'monitors' to performance reports which is an
array of strings:

 *<width>x<height>+<x>+<y>

Where * marks the primary monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 12:34:10 -04:00
Owen W. Taylor
20d579e7d8 Add units to metrics definitions
Switch from having separate METRICS and METRIC_DESCRIPTIONS objects
in a perf module to a single METRICS array. This is done so the
perf module can define the units for each metric.

In addition to improving the output in the web interface, the purpose
of having units is to give some clue about how to pick from multiple
values from different runs. In particular, with the assumption that
"noise" on the system will increase run times, for time values we want
to pick the smallest values, while for "rate" values, we want to pick
the largest value.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
52a68eb24a Add an option to dump a complete performance report
Add --perf-output=<filename> option to gnome-shell that combines
the reports written for each run by the C/Javascript code into
a complete report.

If this option is not specified, a brief human-readable summary
is printed to stdout instead.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
bc57574094 Dump a complete report from a performance run, as JSON
When SHELL_PERF_OUTPUT is set, instead of just dumping out the metrics, dump
a more complete report with:

 - Event descriptions
 - Metric descriptions and value
 - Event log

Helper functions shell_perf_log_dump_events() and shell_perf_log_dump_log()
are added to ShellPerfLog to support this. The gnome-shell wrapper is adapted
to deal with the changed report format.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
e4e92a2b38 Add shell_write_string_to_stream()
Add a helper function to write a string as UTF-8 to a GOutputStream.
The signature of GOutputStream:

 gboolean g_output_stream_write_all (GOutputStream *stream,
                                     const void *buffer,
                                     gsize count,
                                     gsize *bytes_written,
                                     GCancellable *cancellable,
                                     GError **error);

Can't currently be handled by GJS.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
023a274e41 Allow running multiple iterations of a performance test
Add gnome-shell options:

  --perf-iters=ITERS"
    Numbers of iterations of performance module to run
  --perf-warmup
    Run a dry run before performance tests

Make a successful run of a performance test return 0 not non-zero,
and handle the difference between that and a 0-exit in normal
usage (meaning replaced) in the wrapper.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
5d0536d732 Move shell-running machinery to a function
Move the code that starts gnome-shell and waits for it to exit
to a function in preparation for running it multiple times when
doing iterations of a performance test.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
08b8b39a5d Add simple malloc statistics and metrics
Add some basic statistics for allocated memory based on mallinfo(),
and use that to define two metrics:

 usedAfterOverview: bytes used after the overview is shown once
 leakedAfterOverview: additional bytes used when the overview is
   shown a second time.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:45 -04:00
Owen W. Taylor
c972ff3ab4 Add "statistics" functionality to ShellPerfLog
Add a facility for defining and recording numeric statistics
as performance events

 shell_perf_log_define_statistic()
   Define a statistic and the corresponding event type
 shell_perf_log_update_statistic_[ix]() -
   Update the stored statistic value
 shell_perf_log_add_statistics_callback()
   Add a function called before collecting statistics
 shell_perf_collect_statistics()
   Update statistics and record events for them

In addition to the explicit collection, statistics are
recorded at a periodic interval (currently 5s)

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-21 00:18:40 -04:00
Owen W. Taylor
98c2247c1b Add a facility for automated performance measurement
We want to be able to summarize the behavior of the shell's
performance in a series of "metrics", like the latency between
clicking on the Activities button and seeing a response.

This patch adds the ability to create a script under perf/
in a special format that automates a series of actions in the
shell, writing events to the performance log, then collects
statistics as the log as replayed and turns them into a set
of metrics.

The script is then executed by running as gnome-shell
--perf=<script>.

The 'core' script which is added here will be the primary
performance measurement script that we use for shell performance
regression testing; right now it has a couple of placeholder
metrics.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-20 23:41:47 -04:00
Owen W. Taylor
a97b8c1947 Add events before and after stage paint
Add performance events:

 clutter.stagePageStart
 clutter.stagePageDone

to track frame repaints.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-20 23:41:46 -04:00
Owen W. Taylor
1dd2f2c6bc Add ShellPerfLog
ShellPerfLog provides a way for different parts of the code to
record information for subsequent analysis and interactive
exploration. Events exist of a timestamp, an event ID, and
arguments to the event.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-20 23:41:40 -04:00
Owen W. Taylor
a9a513c621 Add "leisure function" capability
To support scheduling performance-measurement scripts that want to run
a number of actions in series, add shell_global_run_at_leisure() to run
a callback when all work is finished.

The initial implementation of this is not that accurate: we track
business in Tweener.js via new shell_global_begin_work(),
shell_global_end_work() functions, and we also handle the case
where the main loop is continually busy.

https://bugzilla.gnome.org/show_bug.cgi?id=618189
2010-05-20 23:21:44 -04:00
Colin Walters
2ce746e7dd [ShellAppSystem] Don't crash if the menu system is empty
This is a bit pathological, but if your menu tree is empty, we
shouldn't crash.
2010-05-20 17:06:30 -04:00
Colin Walters
11cde53108 [main] Explicitly require the Clutter and Gtk versions we want
By default introspection will use "latest", which blows up with
Gtk3.
2010-05-20 17:03:43 -04:00
Dan Winship
fe542f8732 Add a hack to block calls to certain introspected functions
This is useful for keeping people from using methods that only fail in
certain circumstances, by making them fail in all circumstances
instead.

https://bugzilla.gnome.org/show_bug.cgi?id=618918
2010-05-20 15:49:16 -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
5bd7b0dc31 [panel] fix button corners: they should only be rounded on the top 2010-05-20 12:05:22 -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
b6a47cdf76 [telepathy] fix a bug in a last-second fix to the notification changes
https://bugzilla.gnome.org/show_bug.cgi?id=619044
2010-05-19 16:54:33 -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
Mario Blättermann
5cfd72ff8b Updated German translation 2010-05-18 22:08:28 +02:00
Dan Winship
1d721c9080 [panel] add some missing semicolons 2010-05-18 13:16:24 -04:00
Dan Winship
5de1a15d98 magnifier: use global.get_pointer instead of gdk_window_get_pointer
(qv https://bugzilla.gnome.org/show_bug.cgi?id=597292)

https://bugzilla.gnome.org/show_bug.cgi?id=618915
2010-05-17 14:46:26 -04:00
Claude Paroz
b02089c435 Updated French translation 2010-05-17 20:24:47 +02:00
Claude Paroz
ccdc6264da Remove markup from translatable strings 2010-05-17 20:24:33 +02:00
Colin Walters
b736f52037 Rework compare to take into account closed windows
The API docs for ShellApp claimed it sorted by the last time the
user interacted with the app, but if one closed a window, then
we would fall back to comparing against a possibly much older
timestamp from another window.  Fix this by just keeping a
user time per app.

Also clean up the comparison function to explicitly check the state
instead of deferring to the window list.

https://bugzilla.gnome.org/show_bug.cgi?id=618378
2010-05-17 13:37:13 -04:00
Colin Walters
1af392b5f0 Allow selection of individual windows
Per design discussion, change things back so that when choosing
an individual window, we raise only that window.  However
when we select an application, raise all windows.

A behavioral change required to clearly differentiate these
is that when the window thumbnail list is popped up, it no
longer has the first window selected by default.  Therefore
the user has to explicitly press the down arrow or use the
mouse to enter individual window selection mode.

https://bugzilla.gnome.org/show_bug.cgi?id=617959
2010-05-17 13:17:56 -04:00
Colin Walters
84716bccd4 Create ShellGlobal later to avoid connecting to X during build
The ShellGlobal initialization performs several actions like connecting
to the X server, ensuring directories exist, etc., that are problematic
because we were creating the object even when running the binary for
introspection scanning.  During compilation we may not even have X11
available in e.g. autobuilder type environments, and it's just a
bad idea to connect even if we do.

Avoid this by deferring creation of the ShellGlobal object
until the plugin is actually started.

Now that we're initializing things later, remove the connection to
screen changes, and initialize cached ShellGlobal state at the point
when the plugin is set.  The root pixmap actor is now sized initially
on creation too.  Instead of relying on screen-size-changed being
emitted on startup, explicitly invoke _relayout().

https://bugzilla.gnome.org/show_bug.cgi?id=618371
2010-05-17 13:04:38 -04:00
Dan Winship
f438ccfc53 TelepathyClient: show notifications for presence changes
Fetch the names of the user's "subscribed" contacts, and use the
SimplePresence interface to watch for available/away/busy/etc messages
and create notifications for them.

Currently we display notifications when switching between "available"
and "offline"/"extended away", but when switching between "available"
and "away"/"busy" we just add the information to the chat window
without popping up a notification, to avoid spamming the user with
"Bob's screensaver activated" messages.

https://bugzilla.gnome.org/show_bug.cgi?id=611613
2010-05-17 09:58:36 -04:00
Dan Winship
fdd819e9f6 TelepathyClient: track added/removed accounts
(prep work for presence tracking)

https://bugzilla.gnome.org/show_bug.cgi?id=611613
2010-05-17 09:55:31 -04:00