Compare commits
33 Commits
wip/media-
...
wip/re-sea
Author | SHA1 | Date | |
---|---|---|---|
555d45f06c | |||
0a8713770b | |||
7d3ea1ac68 | |||
7785710964 | |||
3730dc01cf | |||
66bf0df737 | |||
4590b33f2e | |||
6538f60322 | |||
4b0ba8b7b8 | |||
bc8965fe63 | |||
e7fcce3484 | |||
b1e4d3335c | |||
a3a3f24ed3 | |||
96191a9c96 | |||
f4814d200b | |||
52156930d3 | |||
cbaa999ced | |||
9491f6bd23 | |||
afe8198d4b | |||
6aa8f14285 | |||
e073670c4d | |||
17a3d2c63f | |||
ca38e05ed4 | |||
9841e56ebf | |||
c0d3a14ac2 | |||
d485fcf9ec | |||
ce2c5106f8 | |||
5e96c3dfb4 | |||
a72b642f3e | |||
8507d3c4e4 | |||
c985fdccba | |||
1d7c2b1c26 | |||
ab60c628e7 |
1
.gitignore
vendored
1
.gitignore
vendored
@ -45,7 +45,6 @@ intltool-merge.in
|
|||||||
intltool-update.in
|
intltool-update.in
|
||||||
libtool
|
libtool
|
||||||
m4/
|
m4/
|
||||||
man/gnome-shell.1
|
|
||||||
omf.make
|
omf.make
|
||||||
po/*.gmo
|
po/*.gmo
|
||||||
po/gnome-shell.pot
|
po/gnome-shell.pot
|
||||||
|
@ -1,11 +1,7 @@
|
|||||||
# Point to our macro directory and pick up user flags from the environment
|
# Point to our macro directory and pick up user flags from the environment
|
||||||
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
|
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
|
||||||
|
|
||||||
SUBDIRS = data js src browser-plugin tests po docs
|
SUBDIRS = data js src browser-plugin tests po man docs
|
||||||
|
|
||||||
if ENABLE_MAN
|
|
||||||
SUBDIRS += man
|
|
||||||
endif
|
|
||||||
|
|
||||||
EXTRA_DIST = \
|
EXTRA_DIST = \
|
||||||
.project \
|
.project \
|
||||||
@ -25,4 +21,4 @@ distcheck-hook:
|
|||||||
@echo "Checking disted files against files in git"
|
@echo "Checking disted files against files in git"
|
||||||
@$(srcdir)/tools/check-for-missing.py $(srcdir) $(distdir) $(DIST_EXCLUDE)
|
@$(srcdir)/tools/check-for-missing.py $(srcdir) $(distdir) $(DIST_EXCLUDE)
|
||||||
|
|
||||||
DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-man
|
DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
|
||||||
|
14
configure.ac
14
configure.ac
@ -36,8 +36,6 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",
|
|||||||
|
|
||||||
PKG_PROG_PKG_CONFIG([0.22])
|
PKG_PROG_PKG_CONFIG([0.22])
|
||||||
|
|
||||||
AC_PATH_PROG([XSLTPROC], [xsltproc])
|
|
||||||
|
|
||||||
GLIB_GSETTINGS
|
GLIB_GSETTINGS
|
||||||
|
|
||||||
# Get a value to substitute into gnome-shell.in
|
# Get a value to substitute into gnome-shell.in
|
||||||
@ -209,18 +207,6 @@ AC_SUBST(TYPELIBDIR)
|
|||||||
|
|
||||||
GTK_DOC_CHECK([1.15], [--flavour no-tmpl])
|
GTK_DOC_CHECK([1.15], [--flavour no-tmpl])
|
||||||
|
|
||||||
AC_ARG_ENABLE(man,
|
|
||||||
[AS_HELP_STRING([--enable-man],
|
|
||||||
[generate man pages [default=yes]])],,
|
|
||||||
enable_man=yes)
|
|
||||||
if test "$enable_man" != no; then
|
|
||||||
AC_PATH_PROG([XSLTPROC], [xsltproc])
|
|
||||||
if test -z "$XSLTPROC"; then
|
|
||||||
AC_MSG_ERROR([xsltproc is required for --enable-man])
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
AM_CONDITIONAL(ENABLE_MAN, test "$enable_man" != no)
|
|
||||||
|
|
||||||
# Stay command-line compatible with the gnome-common configure option. Here
|
# Stay command-line compatible with the gnome-common configure option. Here
|
||||||
# minimum/yes/maximum are the same, however.
|
# minimum/yes/maximum are the same, however.
|
||||||
AC_ARG_ENABLE(compile_warnings,
|
AC_ARG_ENABLE(compile_warnings,
|
||||||
|
@ -8,9 +8,6 @@
|
|||||||
<KeyListEntry name="toggle-message-tray"
|
<KeyListEntry name="toggle-message-tray"
|
||||||
_description="Show the message tray"/>
|
_description="Show the message tray"/>
|
||||||
|
|
||||||
<KeyListEntry name="focus-active-notification"
|
|
||||||
_description="Focus the active notification"/>
|
|
||||||
|
|
||||||
<KeyListEntry name="toggle-application-view"
|
<KeyListEntry name="toggle-application-view"
|
||||||
_description="Show all applications"/>
|
_description="Show all applications"/>
|
||||||
|
|
||||||
|
@ -113,9 +113,13 @@
|
|||||||
<doc:summary>
|
<doc:summary>
|
||||||
<doc:para>
|
<doc:para>
|
||||||
A dictionary describing the given search result, containing
|
A dictionary describing the given search result, containing
|
||||||
'id', 'name' (both strings) and either 'icon' (a serialized
|
'id' and 'name' (both strings). Optionally, either 'gicon' (a
|
||||||
GIcon) or 'icon-data' (raw image data as (iiibiiay) - width,
|
serialized GIcon) or 'icon-data' (raw image data as (iiibiiay)
|
||||||
height, rowstride, has-alpha, bits per sample, channels, data)
|
- width, height, rowstride, has-alpha, bits per sample,
|
||||||
|
channels, data) can be specified if the result can be better
|
||||||
|
served with a thumbnail of the content (such as with images).
|
||||||
|
A 'description' field (string) may also be specified if more
|
||||||
|
context would help the user find the desired result.
|
||||||
</doc:para>
|
</doc:para>
|
||||||
</doc:summary>
|
</doc:summary>
|
||||||
</doc:doc>
|
</doc:doc>
|
||||||
@ -143,5 +147,25 @@
|
|||||||
</doc:doc>
|
</doc:doc>
|
||||||
</arg>
|
</arg>
|
||||||
</method>
|
</method>
|
||||||
|
|
||||||
|
<method name="LaunchSearch">
|
||||||
|
<doc:doc>
|
||||||
|
<doc:description>
|
||||||
|
<doc:para>
|
||||||
|
Called when the user clicks on the provider icon. The provider
|
||||||
|
application should open and run the active search term itself.
|
||||||
|
</doc:para>
|
||||||
|
</doc:description>
|
||||||
|
</doc:doc>
|
||||||
|
<arg type="as" direction="in">
|
||||||
|
<doc:doc>
|
||||||
|
<doc:summary>
|
||||||
|
<doc:para>
|
||||||
|
The current search term(s).
|
||||||
|
</doc:para>
|
||||||
|
</doc:summary>
|
||||||
|
</doc:doc>
|
||||||
|
</arg>
|
||||||
|
</method>
|
||||||
</interface>
|
</interface>
|
||||||
</node>
|
</node>
|
||||||
|
@ -106,13 +106,6 @@ value here is from the GsmPresenceStatus enumeration.</_summary>
|
|||||||
Keybinding to toggle the visibility of the message tray.
|
Keybinding to toggle the visibility of the message tray.
|
||||||
</_description>
|
</_description>
|
||||||
</key>
|
</key>
|
||||||
<key name="focus-active-notification" type="as">
|
|
||||||
<default>["<Super>n"]</default>
|
|
||||||
<_summary>Keybinding to focus the active notification</_summary>
|
|
||||||
<_description>
|
|
||||||
Keybinding to focus the active notification.
|
|
||||||
</_description>
|
|
||||||
</key>
|
|
||||||
<key name="toggle-recording" type="as">
|
<key name="toggle-recording" type="as">
|
||||||
<default><![CDATA[['<Control><Shift><Alt>r']]]></default>
|
<default><![CDATA[['<Control><Shift><Alt>r']]]></default>
|
||||||
<_summary>Keybinding to toggle the screen recorder</_summary>
|
<_summary>Keybinding to toggle the screen recorder</_summary>
|
||||||
|
@ -577,6 +577,10 @@ StScrollBar StButton#vhandle:active {
|
|||||||
spacing: 40px;
|
spacing: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#overview-group {
|
||||||
|
spacing: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
.window-caption {
|
.window-caption {
|
||||||
spacing: 25px;
|
spacing: 25px;
|
||||||
}
|
}
|
||||||
@ -711,7 +715,7 @@ StScrollBar StButton#vhandle:active {
|
|||||||
|
|
||||||
#searchResultsContent {
|
#searchResultsContent {
|
||||||
padding-right: 20px;
|
padding-right: 20px;
|
||||||
spacing: 36px;
|
spacing: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#searchResultsContent:rtl {
|
#searchResultsContent:rtl {
|
||||||
@ -719,6 +723,25 @@ StScrollBar StButton#vhandle:active {
|
|||||||
padding-left: 20px;
|
padding-left: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.search-section {
|
||||||
|
/* This should be equal to #searchResultsContent spacing */
|
||||||
|
spacing: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-section-separator {
|
||||||
|
-gradient-height: 1px;
|
||||||
|
-gradient-start: rgba(255,255,255,0);
|
||||||
|
-gradient-end: rgba(255,255,255,0.5);
|
||||||
|
-margin-horizontal: 1.5em;
|
||||||
|
height: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-section-content {
|
||||||
|
/* This is the space between the provider icon and the results container */
|
||||||
|
spacing: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-statustext,
|
||||||
.search-section-header {
|
.search-section-header {
|
||||||
padding: 4px 12px;
|
padding: 4px 12px;
|
||||||
spacing: 4px;
|
spacing: 4px;
|
||||||
@ -744,6 +767,14 @@ StScrollBar StButton#vhandle:active {
|
|||||||
spacing: 4px;
|
spacing: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.search-providers-box {
|
||||||
|
spacing: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.results-list {
|
||||||
|
spacing: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
/* Text labels are an odd number of pixels tall. The uneven top and bottom
|
/* Text labels are an odd number of pixels tall. The uneven top and bottom
|
||||||
* padding compensates for this and ensures that the label is vertically
|
* padding compensates for this and ensures that the label is vertically
|
||||||
* centered */
|
* centered */
|
||||||
@ -824,7 +855,10 @@ StScrollBar StButton#vhandle:active {
|
|||||||
|
|
||||||
.app-well-app > .overview-icon,
|
.app-well-app > .overview-icon,
|
||||||
.show-apps > .overview-icon,
|
.show-apps > .overview-icon,
|
||||||
.search-result-content > .overview-icon {
|
.remove-favorite > .overview-icon,
|
||||||
|
.search-section-icon-bin,
|
||||||
|
.search-result,
|
||||||
|
.grid-search-result-content > .overview-icon {
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
border: 1px rgba(0,0,0,0);
|
border: 1px rgba(0,0,0,0);
|
||||||
@ -840,7 +874,10 @@ StScrollBar StButton#vhandle:active {
|
|||||||
|
|
||||||
.app-well-app:hover > .overview-icon,
|
.app-well-app:hover > .overview-icon,
|
||||||
.show-apps:hover > .overview-icon,
|
.show-apps:hover > .overview-icon,
|
||||||
.search-result-content:hover > .overview-icon {
|
.remove-favorite:hover > .overview-icon,
|
||||||
|
.search-section-icon-bin:hover,
|
||||||
|
.search-result:hover,
|
||||||
|
.grid-search-result-content:hover > .overview-icon {
|
||||||
background-color: rgba(255,255,255,0.1);
|
background-color: rgba(255,255,255,0.1);
|
||||||
text-shadow: black 0px 2px 2px;
|
text-shadow: black 0px 2px 2px;
|
||||||
transition-duration: 100;
|
transition-duration: 100;
|
||||||
@ -875,13 +912,39 @@ StScrollBar StButton#vhandle:active {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.app-well-app:focus > .overview-icon,
|
.app-well-app:focus > .overview-icon,
|
||||||
.search-result-content:focus > .overview-icon,
|
|
||||||
.show-apps:focus > .overview-icon,
|
.show-apps:focus > .overview-icon,
|
||||||
|
.search-section-icon-bin:focus,
|
||||||
|
.search-result:focus,
|
||||||
|
.grid-search-result-content:focus > .overview-icon,
|
||||||
.app-well-app:selected > .overview-icon,
|
.app-well-app:selected > .overview-icon,
|
||||||
.search-result-content:selected > .overview-icon {
|
.search-section-icon-bin:selected,
|
||||||
|
.search-result:selected,
|
||||||
|
.grid-search-result-content:selected > .overview-icon {
|
||||||
background-color: rgba(255,255,255,0.33);
|
background-color: rgba(255,255,255,0.33);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* List Results */
|
||||||
|
|
||||||
|
.search-result {
|
||||||
|
padding: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result-content {
|
||||||
|
spacing: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result-details {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result-details-title {
|
||||||
|
font-size: 16pt;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-result-details-description {
|
||||||
|
font-size: 14pt;
|
||||||
|
}
|
||||||
|
|
||||||
/* LookingGlass */
|
/* LookingGlass */
|
||||||
|
|
||||||
#LookingGlassDialog {
|
#LookingGlassDialog {
|
||||||
@ -1432,10 +1495,6 @@ StScrollBar StButton#vhandle:active {
|
|||||||
padding-right: 4px;
|
padding-right: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-notification-scrollview{
|
|
||||||
max-height: 22em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.subscription-message {
|
.subscription-message {
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
}
|
}
|
||||||
@ -2325,17 +2384,3 @@ StScrollBar StButton#vhandle:active {
|
|||||||
padding-bottom: 0px;
|
padding-bottom: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.osd-window {
|
|
||||||
color: #ededed;
|
|
||||||
background-color: rgba(33, 37, 38, 0.80);
|
|
||||||
border-radius: 15px;
|
|
||||||
text-shadow: 0 1px rgba(0, 0, 0, 0.75);
|
|
||||||
|
|
||||||
padding: 40px;
|
|
||||||
spacing: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.osd-progress-bar {
|
|
||||||
height: 0.8em;
|
|
||||||
border: 1px solid;
|
|
||||||
}
|
|
||||||
|
@ -41,6 +41,7 @@ nobase_dist_js_DATA = \
|
|||||||
ui/boxpointer.js \
|
ui/boxpointer.js \
|
||||||
ui/calendar.js \
|
ui/calendar.js \
|
||||||
ui/checkBox.js \
|
ui/checkBox.js \
|
||||||
|
ui/centerLayout.js \
|
||||||
ui/ctrlAltTab.js \
|
ui/ctrlAltTab.js \
|
||||||
ui/dash.js \
|
ui/dash.js \
|
||||||
ui/dateMenu.js \
|
ui/dateMenu.js \
|
||||||
@ -100,7 +101,6 @@ nobase_dist_js_DATA = \
|
|||||||
ui/components/__init__.js \
|
ui/components/__init__.js \
|
||||||
ui/components/autorunManager.js \
|
ui/components/autorunManager.js \
|
||||||
ui/components/automountManager.js \
|
ui/components/automountManager.js \
|
||||||
ui/components/mediaKeysManager.js \
|
|
||||||
ui/components/networkAgent.js \
|
ui/components/networkAgent.js \
|
||||||
ui/components/polkitAgent.js \
|
ui/components/polkitAgent.js \
|
||||||
ui/components/recorder.js \
|
ui/components/recorder.js \
|
||||||
|
@ -684,10 +684,9 @@ const LoginDialog = new Lang.Class({
|
|||||||
this._userVerifier = new GdmUtil.ShellUserVerifier(this._greeterClient);
|
this._userVerifier = new GdmUtil.ShellUserVerifier(this._greeterClient);
|
||||||
this._userVerifier.connect('ask-question', Lang.bind(this, this._askQuestion));
|
this._userVerifier.connect('ask-question', Lang.bind(this, this._askQuestion));
|
||||||
this._userVerifier.connect('show-message', Lang.bind(this, this._showMessage));
|
this._userVerifier.connect('show-message', Lang.bind(this, this._showMessage));
|
||||||
this._userVerifier.connect('reset', Lang.bind(this, this._reset));
|
this._userVerifier.connect('reset', Lang.bind(this, this._onReset));
|
||||||
this._userVerifier.connect('show-login-hint', Lang.bind(this, this._showLoginHint));
|
this._userVerifier.connect('show-login-hint', Lang.bind(this, this._showLoginHint));
|
||||||
this._userVerifier.connect('hide-login-hint', Lang.bind(this, this._hideLoginHint));
|
this._userVerifier.connect('hide-login-hint', Lang.bind(this, this._hideLoginHint));
|
||||||
this._verifyingUser = false;
|
|
||||||
|
|
||||||
this._settings = new Gio.Settings({ schema: GdmUtil.LOGIN_SCREEN_SCHEMA });
|
this._settings = new Gio.Settings({ schema: GdmUtil.LOGIN_SCREEN_SCHEMA });
|
||||||
|
|
||||||
@ -695,8 +694,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
Lang.bind(this, this._updateBanner));
|
Lang.bind(this, this._updateBanner));
|
||||||
this._settings.connect('changed::' + GdmUtil.BANNER_MESSAGE_TEXT_KEY,
|
this._settings.connect('changed::' + GdmUtil.BANNER_MESSAGE_TEXT_KEY,
|
||||||
Lang.bind(this, this._updateBanner));
|
Lang.bind(this, this._updateBanner));
|
||||||
this._settings.connect('changed::' + GdmUtil.DISABLE_USER_LIST_KEY,
|
|
||||||
Lang.bind(this, this._updateDisableUserList));
|
|
||||||
|
|
||||||
this._bannerLabel = new St.Label({ style_class: 'login-dialog-banner',
|
this._bannerLabel = new St.Label({ style_class: 'login-dialog-banner',
|
||||||
text: '' });
|
text: '' });
|
||||||
@ -704,8 +701,7 @@ const LoginDialog = new Lang.Class({
|
|||||||
this._updateBanner();
|
this._updateBanner();
|
||||||
|
|
||||||
this._titleLabel = new St.Label({ style_class: 'login-dialog-title',
|
this._titleLabel = new St.Label({ style_class: 'login-dialog-title',
|
||||||
text: C_("title", "Sign In"),
|
text: C_("title", "Sign In") });
|
||||||
visible: false });
|
|
||||||
|
|
||||||
this.contentLayout.add(this._titleLabel,
|
this.contentLayout.add(this._titleLabel,
|
||||||
{ y_fill: false,
|
{ y_fill: false,
|
||||||
@ -735,7 +731,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
x_align: St.Align.START });
|
x_align: St.Align.START });
|
||||||
this._promptEntry = new St.Entry({ style_class: 'login-dialog-prompt-entry',
|
this._promptEntry = new St.Entry({ style_class: 'login-dialog-prompt-entry',
|
||||||
can_focus: true });
|
can_focus: true });
|
||||||
this._promptEntryTextChangedId = 0;
|
|
||||||
this._promptBox.add(this._promptEntry,
|
this._promptBox.add(this._promptEntry,
|
||||||
{ expand: true,
|
{ expand: true,
|
||||||
x_fill: true,
|
x_fill: true,
|
||||||
@ -774,7 +769,7 @@ const LoginDialog = new Lang.Class({
|
|||||||
x_align: St.Align.START,
|
x_align: St.Align.START,
|
||||||
x_fill: true });
|
x_fill: true });
|
||||||
|
|
||||||
this._notListedButton.connect('clicked', Lang.bind(this, this._hideUserListAndLogIn));
|
this._notListedButton.connect('clicked', Lang.bind(this, this._onNotListedClicked));
|
||||||
|
|
||||||
this.contentLayout.add(this._notListedButton,
|
this.contentLayout.add(this._notListedButton,
|
||||||
{ expand: false,
|
{ expand: false,
|
||||||
@ -800,21 +795,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_updateDisableUserList: function() {
|
|
||||||
let disableUserList = this._settings.get_boolean(GdmUtil.DISABLE_USER_LIST_KEY);
|
|
||||||
|
|
||||||
// If this is the first time around, set initial focus
|
|
||||||
if (this._disableUserList == undefined && disableUserList)
|
|
||||||
this.setInitialKeyFocus(this._promptEntry);
|
|
||||||
|
|
||||||
if (disableUserList != this._disableUserList) {
|
|
||||||
this._disableUserList = disableUserList;
|
|
||||||
|
|
||||||
if (!this._verifyingUser)
|
|
||||||
this._reset();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
_updateBanner: function() {
|
_updateBanner: function() {
|
||||||
let enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
let enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
||||||
let text = this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
let text = this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
||||||
@ -827,15 +807,31 @@ const LoginDialog = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
_reset: function() {
|
_onReset: function(client, serviceName) {
|
||||||
this._promptMessage.hide();
|
this._promptMessage.hide();
|
||||||
this._user = null;
|
|
||||||
this._verifyingUser = false;
|
|
||||||
|
|
||||||
if (this._disableUserList)
|
let tasks = [this._hidePrompt,
|
||||||
this._hideUserListAndLogIn();
|
|
||||||
else
|
new Batch.ConcurrentBatch(this, [this._fadeInTitleLabel,
|
||||||
this._showUserList();
|
this._fadeInNotListedButton]),
|
||||||
|
|
||||||
|
function() {
|
||||||
|
this._sessionList.close();
|
||||||
|
this._promptLoginHint.hide();
|
||||||
|
this._userList.actor.show();
|
||||||
|
this._userList.actor.opacity = 255;
|
||||||
|
return this._userList.showItems();
|
||||||
|
},
|
||||||
|
|
||||||
|
function() {
|
||||||
|
this._userList.actor.reactive = true;
|
||||||
|
this._userList.actor.grab_key_focus();
|
||||||
|
}];
|
||||||
|
|
||||||
|
this._user = null;
|
||||||
|
|
||||||
|
let batch = new Batch.ConsecutiveBatch(this, tasks);
|
||||||
|
batch.run();
|
||||||
},
|
},
|
||||||
|
|
||||||
_onDefaultSessionChanged: function(client, sessionId) {
|
_onDefaultSessionChanged: function(client, sessionId) {
|
||||||
@ -890,9 +886,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
if (this._user && this._user.is_logged_in())
|
if (this._user && this._user.is_logged_in())
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
if (!this._verifyingUser)
|
|
||||||
return null;
|
|
||||||
|
|
||||||
return GdmUtil.fadeInActor(this._sessionList.actor);
|
return GdmUtil.fadeInActor(this._sessionList.actor);
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -905,21 +898,17 @@ const LoginDialog = new Lang.Class({
|
|||||||
return batch.run();
|
return batch.run();
|
||||||
},
|
},
|
||||||
|
|
||||||
_showPrompt: function(forSecret) {
|
_showPrompt: function() {
|
||||||
let hold = new Batch.Hold();
|
let hold = new Batch.Hold();
|
||||||
|
|
||||||
let cancelButtonInfo = { action: Lang.bind(this, this.cancel),
|
let buttons = [{ action: Lang.bind(this, this.cancel),
|
||||||
label: _("Cancel"),
|
label: _("Cancel"),
|
||||||
key: Clutter.Escape };
|
key: Clutter.Escape },
|
||||||
let okButtonInfo = { action: Lang.bind(this, function() {
|
{ action: Lang.bind(this, function() {
|
||||||
hold.release();
|
hold.release();
|
||||||
}),
|
}),
|
||||||
label: forSecret ? C_("button", "Sign In") : _("Next"),
|
label: C_("button", "Sign In"),
|
||||||
default: true };
|
default: true }];
|
||||||
let buttons = [];
|
|
||||||
if (!this._disableUserList || this._verifyingUser)
|
|
||||||
buttons.push(cancelButtonInfo);
|
|
||||||
buttons.push(okButtonInfo);
|
|
||||||
|
|
||||||
let tasks = [function() {
|
let tasks = [function() {
|
||||||
return this._fadeInPrompt();
|
return this._fadeInPrompt();
|
||||||
@ -927,16 +916,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
|
|
||||||
function() {
|
function() {
|
||||||
this.setButtons(buttons);
|
this.setButtons(buttons);
|
||||||
|
|
||||||
let updateOkButtonEnabled = Lang.bind(this, function() {
|
|
||||||
let sensitive = this._promptEntry.text.length > 0;
|
|
||||||
okButtonInfo.button.reactive = sensitive;
|
|
||||||
okButtonInfo.button.can_focus = sensitive;
|
|
||||||
});
|
|
||||||
|
|
||||||
updateOkButtonEnabled();
|
|
||||||
|
|
||||||
this._promptEntryTextChangedId = this._promptEntry.clutter_text.connect('text-changed', updateOkButtonEnabled);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
hold];
|
hold];
|
||||||
@ -949,11 +928,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
_hidePrompt: function() {
|
_hidePrompt: function() {
|
||||||
this.setButtons([]);
|
this.setButtons([]);
|
||||||
|
|
||||||
if (this._promptEntryTextChangedId > 0) {
|
|
||||||
this._promptEntry.clutter_text.disconnect(this._promptEntryTextChangedId);
|
|
||||||
this._promptEntryTextChangedId = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
let tasks = [function() {
|
let tasks = [function() {
|
||||||
return GdmUtil.fadeOutActor(this._promptBox);
|
return GdmUtil.fadeOutActor(this._promptBox);
|
||||||
},
|
},
|
||||||
@ -975,9 +949,7 @@ const LoginDialog = new Lang.Class({
|
|||||||
this._promptEntry.set_text('');
|
this._promptEntry.set_text('');
|
||||||
this._promptEntry.clutter_text.set_password_char(passwordChar);
|
this._promptEntry.clutter_text.set_password_char(passwordChar);
|
||||||
|
|
||||||
let tasks = [function() {
|
let tasks = [this._showPrompt,
|
||||||
return this._showPrompt(!!passwordChar);
|
|
||||||
},
|
|
||||||
|
|
||||||
function() {
|
function() {
|
||||||
let _text = this._promptEntry.get_text();
|
let _text = this._promptEntry.get_text();
|
||||||
@ -989,23 +961,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
return batch.run();
|
return batch.run();
|
||||||
},
|
},
|
||||||
|
|
||||||
_askForUsernameAndLogIn: function() {
|
|
||||||
this._promptLabel.set_text(_("Username: "));
|
|
||||||
this._promptEntry.set_text('');
|
|
||||||
this._promptEntry.clutter_text.set_password_char('');
|
|
||||||
|
|
||||||
let tasks = [this._showPrompt,
|
|
||||||
|
|
||||||
function() {
|
|
||||||
let userName = this._promptEntry.get_text();
|
|
||||||
this._promptEntry.reactive = false;
|
|
||||||
return this._beginVerificationForUser(userName);
|
|
||||||
}];
|
|
||||||
|
|
||||||
let batch = new Batch.ConsecutiveBatch(this, tasks);
|
|
||||||
return batch.run();
|
|
||||||
},
|
|
||||||
|
|
||||||
_onSessionOpened: function(client, serviceName) {
|
_onSessionOpened: function(client, serviceName) {
|
||||||
this._greeter.call_start_session_when_ready_sync(serviceName, true, null);
|
this._greeter.call_start_session_when_ready_sync(serviceName, true, null);
|
||||||
},
|
},
|
||||||
@ -1134,7 +1089,7 @@ const LoginDialog = new Lang.Class({
|
|||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
|
|
||||||
_hideUserListAndLogIn: function() {
|
_onNotListedClicked: function(user) {
|
||||||
let tasks = [function() {
|
let tasks = [function() {
|
||||||
return this._userList.hideItems();
|
return this._userList.hideItems();
|
||||||
},
|
},
|
||||||
@ -1151,30 +1106,10 @@ const LoginDialog = new Lang.Class({
|
|||||||
this._fadeOutNotListedButton]),
|
this._fadeOutNotListedButton]),
|
||||||
|
|
||||||
function() {
|
function() {
|
||||||
return this._askForUsernameAndLogIn();
|
let hold = new Batch.Hold();
|
||||||
}];
|
|
||||||
|
|
||||||
let batch = new Batch.ConsecutiveBatch(this, tasks);
|
this._userVerifier.begin(null, hold);
|
||||||
batch.run();
|
return hold;
|
||||||
},
|
|
||||||
|
|
||||||
_showUserList: function() {
|
|
||||||
let tasks = [this._hidePrompt,
|
|
||||||
|
|
||||||
new Batch.ConcurrentBatch(this, [this._fadeInTitleLabel,
|
|
||||||
this._fadeInNotListedButton]),
|
|
||||||
|
|
||||||
function() {
|
|
||||||
this._sessionList.close();
|
|
||||||
this._promptLoginHint.hide();
|
|
||||||
this._userList.actor.show();
|
|
||||||
this._userList.actor.opacity = 255;
|
|
||||||
return this._userList.showItems();
|
|
||||||
},
|
|
||||||
|
|
||||||
function() {
|
|
||||||
this._userList.actor.reactive = true;
|
|
||||||
this._userList.actor.grab_key_focus();
|
|
||||||
}];
|
}];
|
||||||
|
|
||||||
let batch = new Batch.ConsecutiveBatch(this, tasks);
|
let batch = new Batch.ConsecutiveBatch(this, tasks);
|
||||||
@ -1209,7 +1144,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
let hold = new Batch.Hold();
|
let hold = new Batch.Hold();
|
||||||
|
|
||||||
this._userVerifier.begin(userName, hold);
|
this._userVerifier.begin(userName, hold);
|
||||||
this._verifyingUser = true;
|
|
||||||
return hold;
|
return hold;
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -1262,8 +1196,6 @@ const LoginDialog = new Lang.Class({
|
|||||||
this._userList.addUser(users[i]);
|
this._userList.addUser(users[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
this._updateDisableUserList();
|
|
||||||
|
|
||||||
this._userManager.connect('user-added',
|
this._userManager.connect('user-added',
|
||||||
Lang.bind(this, function(userManager, user) {
|
Lang.bind(this, function(userManager, user) {
|
||||||
this._userList.addUser(user);
|
this._userList.addUser(user);
|
||||||
|
@ -23,7 +23,6 @@ const BANNER_MESSAGE_TEXT_KEY = 'banner-message-text';
|
|||||||
const ALLOWED_FAILURES_KEY = 'allowed-failures';
|
const ALLOWED_FAILURES_KEY = 'allowed-failures';
|
||||||
|
|
||||||
const LOGO_KEY = 'logo';
|
const LOGO_KEY = 'logo';
|
||||||
const DISABLE_USER_LIST_KEY = 'disable-user-list';
|
|
||||||
|
|
||||||
function fadeInActor(actor) {
|
function fadeInActor(actor) {
|
||||||
if (actor.opacity == 255 && actor.visible)
|
if (actor.opacity == 255 && actor.visible)
|
||||||
|
@ -17,9 +17,6 @@ const SystemdLoginManagerIface = <interface name='org.freedesktop.login1.Manager
|
|||||||
<method name='Suspend'>
|
<method name='Suspend'>
|
||||||
<arg type='b' direction='in'/>
|
<arg type='b' direction='in'/>
|
||||||
</method>
|
</method>
|
||||||
<method name='Hibernate'>
|
|
||||||
<arg type='b' direction='in'/>
|
|
||||||
</method>
|
|
||||||
<method name='CanPowerOff'>
|
<method name='CanPowerOff'>
|
||||||
<arg type='s' direction='out'/>
|
<arg type='s' direction='out'/>
|
||||||
</method>
|
</method>
|
||||||
@ -29,9 +26,6 @@ const SystemdLoginManagerIface = <interface name='org.freedesktop.login1.Manager
|
|||||||
<method name='CanSuspend'>
|
<method name='CanSuspend'>
|
||||||
<arg type='s' direction='out'/>
|
<arg type='s' direction='out'/>
|
||||||
</method>
|
</method>
|
||||||
<method name='CanHibernate'>
|
|
||||||
<arg type='s' direction='out'/>
|
|
||||||
</method>
|
|
||||||
</interface>;
|
</interface>;
|
||||||
|
|
||||||
const SystemdLoginSessionIface = <interface name='org.freedesktop.login1.Session'>
|
const SystemdLoginSessionIface = <interface name='org.freedesktop.login1.Session'>
|
||||||
@ -146,15 +140,6 @@ const LoginManagerSystemd = new Lang.Class({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
canHibernate: function(asyncCallback) {
|
|
||||||
this._proxy.CanSuspendRemote(function(result, error) {
|
|
||||||
if (error)
|
|
||||||
asyncCallback(false);
|
|
||||||
else
|
|
||||||
asyncCallback(result[0] != 'no');
|
|
||||||
});
|
|
||||||
},
|
|
||||||
|
|
||||||
powerOff: function() {
|
powerOff: function() {
|
||||||
this._proxy.PowerOffRemote(true);
|
this._proxy.PowerOffRemote(true);
|
||||||
},
|
},
|
||||||
@ -165,10 +150,6 @@ const LoginManagerSystemd = new Lang.Class({
|
|||||||
|
|
||||||
suspend: function() {
|
suspend: function() {
|
||||||
this._proxy.SuspendRemote(true);
|
this._proxy.SuspendRemote(true);
|
||||||
},
|
|
||||||
|
|
||||||
hibernate: function() {
|
|
||||||
this._proxy.HibernateRemote(true);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -234,13 +215,6 @@ const LoginManagerConsoleKit = new Lang.Class({
|
|||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
|
|
||||||
canHibernate: function(asyncCallback) {
|
|
||||||
Mainloop.idle_add(Lang.bind(this, function() {
|
|
||||||
asyncCallback(this._upClient.get_can_hibernate());
|
|
||||||
return false;
|
|
||||||
}));
|
|
||||||
},
|
|
||||||
|
|
||||||
powerOff: function() {
|
powerOff: function() {
|
||||||
this._proxy.StopRemote();
|
this._proxy.StopRemote();
|
||||||
},
|
},
|
||||||
@ -251,9 +225,5 @@ const LoginManagerConsoleKit = new Lang.Class({
|
|||||||
|
|
||||||
suspend: function() {
|
suspend: function() {
|
||||||
this._upClient.suspend_sync(null);
|
this._upClient.suspend_sync(null);
|
||||||
},
|
|
||||||
|
|
||||||
hibernate: function() {
|
|
||||||
this._upClient.hibernate_sync(null);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -46,70 +46,8 @@ let _providersTable;
|
|||||||
function _getProvidersTable() {
|
function _getProvidersTable() {
|
||||||
if (_providersTable)
|
if (_providersTable)
|
||||||
return _providersTable;
|
return _providersTable;
|
||||||
return _providersTable = Shell.mobile_providers_parse(null,null);
|
let [providers, countryCodes] = Shell.mobile_providers_parse();
|
||||||
}
|
return _providersTable = providers;
|
||||||
|
|
||||||
function findProviderForMCCMNC(table, needle) {
|
|
||||||
let needlemcc = needle.substring(0, 3);
|
|
||||||
let needlemnc = needle.substring(3, needle.length);
|
|
||||||
|
|
||||||
let name2, name3;
|
|
||||||
for (let iter in table) {
|
|
||||||
let country = table[iter];
|
|
||||||
let providers = country.get_providers();
|
|
||||||
|
|
||||||
// Search through each country's providers
|
|
||||||
for (let i = 0; i < providers.length; i++) {
|
|
||||||
let provider = providers[i];
|
|
||||||
|
|
||||||
// Search through MCC/MNC list
|
|
||||||
let list = provider.get_gsm_mcc_mnc();
|
|
||||||
for (let j = 0; j < list.length; j++) {
|
|
||||||
let mccmnc = list[j];
|
|
||||||
|
|
||||||
// Match both 2-digit and 3-digit MNC; prefer a
|
|
||||||
// 3-digit match if found, otherwise a 2-digit one.
|
|
||||||
if (mccmnc.mcc != needlemcc)
|
|
||||||
continue; // MCC was wrong
|
|
||||||
|
|
||||||
if (!name3 && needle.length == 6 && needlemnc == mccmnc.mnc)
|
|
||||||
name3 = provider.name;
|
|
||||||
|
|
||||||
if (!name2 && needlemnc.substring(0, 2) == mccmnc.mnc.substring(0, 2))
|
|
||||||
name2 = provider.name;
|
|
||||||
|
|
||||||
if (name2 && name3)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return name3 || name2 || null;
|
|
||||||
}
|
|
||||||
|
|
||||||
function findProviderForSid(table, sid) {
|
|
||||||
if (sid == 0)
|
|
||||||
return null;
|
|
||||||
|
|
||||||
// Search through each country
|
|
||||||
for (let iter in table) {
|
|
||||||
let country = table[iter];
|
|
||||||
let providers = country.get_providers();
|
|
||||||
|
|
||||||
// Search through each country's providers
|
|
||||||
for (let i = 0; i < providers.length; i++) {
|
|
||||||
let provider = providers[i];
|
|
||||||
let cdma_sid = provider.get_cdma_sid();
|
|
||||||
|
|
||||||
// Search through CDMA SID list
|
|
||||||
for (let j = 0; j < cdma_sid.length; j++) {
|
|
||||||
if (cdma_sid[j] == sid)
|
|
||||||
return provider.name;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const ModemGsm = new Lang.Class({
|
const ModemGsm = new Lang.Class({
|
||||||
@ -153,8 +91,7 @@ const ModemGsm = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_findOperatorName: function(name, opCode) {
|
_findOperatorName: function(name, opCode) {
|
||||||
if (name) {
|
if (name.length != 0 && (name.length > 6 || name.length < 5)) {
|
||||||
if (name && name.length != 0 && (name.length > 6 || name.length < 5)) {
|
|
||||||
// this looks like a valid name, i.e. not an MCCMNC (that some
|
// this looks like a valid name, i.e. not an MCCMNC (that some
|
||||||
// devices return when not yet connected
|
// devices return when not yet connected
|
||||||
return name;
|
return name;
|
||||||
@ -164,18 +101,54 @@ const ModemGsm = new Lang.Class({
|
|||||||
// after all; return that
|
// after all; return that
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
let needle;
|
let needle;
|
||||||
if ((name == null || name.length == 0) && opCode)
|
if (name.length == 0 && opCode)
|
||||||
needle = opCode;
|
needle = opCode;
|
||||||
else if (name.length == 6 || name.length == 5)
|
else if (name.length == 6 || name.length == 5)
|
||||||
needle = name;
|
needle = name;
|
||||||
else // nothing to search
|
else // nothing to search
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
|
return this._findProviderForMCCMNC(needle);
|
||||||
|
},
|
||||||
|
|
||||||
|
_findProviderForMCCMNC: function(needle) {
|
||||||
let table = _getProvidersTable();
|
let table = _getProvidersTable();
|
||||||
return findProviderForMCCMNC(table, needle);
|
let needlemcc = needle.substring(0, 3);
|
||||||
|
let needlemnc = needle.substring(3, needle.length);
|
||||||
|
|
||||||
|
let name2, name3;
|
||||||
|
for (let iter in table) {
|
||||||
|
let providers = table[iter];
|
||||||
|
|
||||||
|
// Search through each country's providers
|
||||||
|
for (let i = 0; i < providers.length; i++) {
|
||||||
|
let provider = providers[i];
|
||||||
|
|
||||||
|
// Search through MCC/MNC list
|
||||||
|
let list = provider.get_gsm_mcc_mnc();
|
||||||
|
for (let j = 0; j < list.length; j++) {
|
||||||
|
let mccmnc = list[j];
|
||||||
|
|
||||||
|
// Match both 2-digit and 3-digit MNC; prefer a
|
||||||
|
// 3-digit match if found, otherwise a 2-digit one.
|
||||||
|
if (mccmnc.mcc != needlemcc)
|
||||||
|
continue; // MCC was wrong
|
||||||
|
|
||||||
|
if (!name3 && needle.length == 6 && needlemnc == mccmnc.mnc)
|
||||||
|
name3 = provider.name;
|
||||||
|
|
||||||
|
if (!name2 && needlemnc.substring(0, 2) == mccmnc.mnc.substring(0, 2))
|
||||||
|
name2 = provider.name;
|
||||||
|
|
||||||
|
if (name2 && name3)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return name3 || name2 || null;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(ModemGsm.prototype);
|
Signals.addSignalMethods(ModemGsm.prototype);
|
||||||
@ -216,14 +189,39 @@ const ModemCdma = new Lang.Class({
|
|||||||
this.operator_name = null;
|
this.operator_name = null;
|
||||||
} else {
|
} else {
|
||||||
let [bandClass, band, id] = result;
|
let [bandClass, band, id] = result;
|
||||||
if (name.length > 0) {
|
if (name.length > 0)
|
||||||
let table = _getProvidersTable();
|
this.operator_name = this._findProviderForSid(id);
|
||||||
this.operator_name = findProviderForSid(table, id);
|
else
|
||||||
} else
|
|
||||||
this.operator_name = null;
|
this.operator_name = null;
|
||||||
}
|
}
|
||||||
this.emit('notify::operator-name');
|
this.emit('notify::operator-name');
|
||||||
}));
|
}));
|
||||||
|
},
|
||||||
|
|
||||||
|
_findProviderForSid: function(sid) {
|
||||||
|
if (sid == 0)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
let table = _getProvidersTable();
|
||||||
|
|
||||||
|
// Search through each country
|
||||||
|
for (let iter in table) {
|
||||||
|
let providers = table[iter];
|
||||||
|
|
||||||
|
// Search through each country's providers
|
||||||
|
for (let i = 0; i < providers.length; i++) {
|
||||||
|
let provider = providers[i];
|
||||||
|
let cdma_sid = provider.get_cdma_sid();
|
||||||
|
|
||||||
|
// Search through CDMA SID list
|
||||||
|
for (let j = 0; j < cdma_sid.length; j++) {
|
||||||
|
if (cdma_sid[j] == sid)
|
||||||
|
return provider.name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(ModemCdma.prototype);
|
Signals.addSignalMethods(ModemCdma.prototype);
|
||||||
|
@ -288,31 +288,3 @@ function insertSorted(array, val, cmp) {
|
|||||||
|
|
||||||
return pos;
|
return pos;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* wrapKeybinding:
|
|
||||||
*
|
|
||||||
* Wrap a keybinding handler so that
|
|
||||||
* it ignores an invocation if the shell is modal, but
|
|
||||||
* not when the overview is active, or when global
|
|
||||||
* keybindings are allowed by session mode.
|
|
||||||
* This function is only useful for keybindings installed
|
|
||||||
* with Meta.KeybindingFlags.HANDLE_WHEN_GRABBED
|
|
||||||
*/
|
|
||||||
function wrapKeybinding(handler, onlyInOverview) {
|
|
||||||
return function() {
|
|
||||||
let handle;
|
|
||||||
|
|
||||||
if (onlyInOverview) {
|
|
||||||
handle = Main.sessionMode.allowKeybindingsWhenModal ||
|
|
||||||
Main.modalCount == (Main.overview.visible ? 1 : 0);
|
|
||||||
} else {
|
|
||||||
handle = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (handle)
|
|
||||||
return handler.apply(this, arguments);
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -199,7 +199,7 @@ const AltTabPopup = new Lang.Class({
|
|||||||
this.actor.get_allocation_box();
|
this.actor.get_allocation_box();
|
||||||
|
|
||||||
// Make the initial selection
|
// Make the initial selection
|
||||||
if (binding == 'internal-keybinding-switch-group') {
|
if (binding == 'switch-group') {
|
||||||
if (backward) {
|
if (backward) {
|
||||||
this._select(0, this._appIcons[0].cachedWindows.length - 1);
|
this._select(0, this._appIcons[0].cachedWindows.length - 1);
|
||||||
} else {
|
} else {
|
||||||
@ -208,9 +208,9 @@ const AltTabPopup = new Lang.Class({
|
|||||||
else
|
else
|
||||||
this._select(0, 0);
|
this._select(0, 0);
|
||||||
}
|
}
|
||||||
} else if (binding == 'internal-keybinding-switch-group-backward') {
|
} else if (binding == 'switch-group-backward') {
|
||||||
this._select(0, this._appIcons[0].cachedWindows.length - 1);
|
this._select(0, this._appIcons[0].cachedWindows.length - 1);
|
||||||
} else if (binding == 'internal-keybinding-switch-windows-backward') {
|
} else if (binding == 'switch-windows-backward') {
|
||||||
this._select(this._appIcons.length - 1);
|
this._select(this._appIcons.length - 1);
|
||||||
} else if (this._appIcons.length == 1) {
|
} else if (this._appIcons.length == 1) {
|
||||||
this._select(0);
|
this._select(0);
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
|
|
||||||
const Clutter = imports.gi.Clutter;
|
const Clutter = imports.gi.Clutter;
|
||||||
|
const Gio = imports.gi.Gio;
|
||||||
const GLib = imports.gi.GLib;
|
const GLib = imports.gi.GLib;
|
||||||
const Gtk = imports.gi.Gtk;
|
const Gtk = imports.gi.Gtk;
|
||||||
const GMenu = imports.gi.GMenu;
|
const GMenu = imports.gi.GMenu;
|
||||||
@ -371,6 +372,8 @@ const SettingsSearchProvider = new Lang.Class({
|
|||||||
|
|
||||||
this._appSys = Shell.AppSystem.get_default();
|
this._appSys = Shell.AppSystem.get_default();
|
||||||
this._gnomecc = this._appSys.lookup_app('gnome-control-center.desktop');
|
this._gnomecc = this._appSys.lookup_app('gnome-control-center.desktop');
|
||||||
|
let appInfo = Gio.DesktopAppInfo.new('gnome-control-center.desktop');
|
||||||
|
this.icon = appInfo.get_icon();
|
||||||
},
|
},
|
||||||
|
|
||||||
getResultMetas: function(prefs, callback) {
|
getResultMetas: function(prefs, callback) {
|
||||||
@ -379,9 +382,7 @@ const SettingsSearchProvider = new Lang.Class({
|
|||||||
let pref = prefs[i];
|
let pref = prefs[i];
|
||||||
metas.push({ 'id': pref,
|
metas.push({ 'id': pref,
|
||||||
'name': pref.get_name(),
|
'name': pref.get_name(),
|
||||||
'createIcon': function(size) {
|
'createIcon': function(size) { return; }
|
||||||
return pref.create_icon_texture(size);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
callback(metas);
|
callback(metas);
|
||||||
@ -461,15 +462,15 @@ const AppWellIcon = new Lang.Class({
|
|||||||
this._draggable.connect('drag-begin', Lang.bind(this,
|
this._draggable.connect('drag-begin', Lang.bind(this,
|
||||||
function () {
|
function () {
|
||||||
this._removeMenuTimeout();
|
this._removeMenuTimeout();
|
||||||
Main.overview.beginItemDrag(this);
|
Main.overview.beginAppDrag(this);
|
||||||
}));
|
}));
|
||||||
this._draggable.connect('drag-cancelled', Lang.bind(this,
|
this._draggable.connect('drag-cancelled', Lang.bind(this,
|
||||||
function () {
|
function () {
|
||||||
Main.overview.cancelledItemDrag(this);
|
Main.overview.cancelledAppDrag(this);
|
||||||
}));
|
}));
|
||||||
this._draggable.connect('drag-end', Lang.bind(this,
|
this._draggable.connect('drag-end', Lang.bind(this,
|
||||||
function () {
|
function () {
|
||||||
Main.overview.endItemDrag(this);
|
Main.overview.endAppDrag(this);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
this.actor.connect('destroy', Lang.bind(this, this._onDestroy));
|
this.actor.connect('destroy', Lang.bind(this, this._onDestroy));
|
||||||
@ -479,6 +480,7 @@ const AppWellIcon = new Lang.Class({
|
|||||||
Lang.bind(this,
|
Lang.bind(this,
|
||||||
this._onStateChanged));
|
this._onStateChanged));
|
||||||
this._onStateChanged();
|
this._onStateChanged();
|
||||||
|
this.isMenuUp = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onDestroy: function() {
|
_onDestroy: function() {
|
||||||
@ -560,8 +562,7 @@ const AppWellIcon = new Lang.Class({
|
|||||||
this._menuManager.addMenu(this._menu);
|
this._menuManager.addMenu(this._menu);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.emit('menu-state-changed', true);
|
this.isMenuUp = true;
|
||||||
|
|
||||||
this.actor.set_hover(true);
|
this.actor.set_hover(true);
|
||||||
this._menu.popup();
|
this._menu.popup();
|
||||||
|
|
||||||
@ -578,7 +579,7 @@ const AppWellIcon = new Lang.Class({
|
|||||||
|
|
||||||
_onMenuPoppedDown: function() {
|
_onMenuPoppedDown: function() {
|
||||||
this.actor.sync_hover();
|
this.actor.sync_hover();
|
||||||
this.emit('menu-state-changed', false);
|
this.isMenuUp = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onActivate: function (event) {
|
_onActivate: function (event) {
|
||||||
|
@ -84,12 +84,9 @@ const AppFavorites = new Lang.Class({
|
|||||||
|
|
||||||
let app = Shell.AppSystem.get_default().lookup_app(appId);
|
let app = Shell.AppSystem.get_default().lookup_app(appId);
|
||||||
|
|
||||||
Main.overview.setMessage(_("%s has been added to your favorites.").format(app.get_name()),
|
Main.overview.setMessage(_("%s has been added to your favorites.").format(app.get_name()), Lang.bind(this, function () {
|
||||||
{ forFeedback: true,
|
|
||||||
undoCallback: Lang.bind(this, function () {
|
|
||||||
this._removeFavorite(appId);
|
this._removeFavorite(appId);
|
||||||
})
|
}));
|
||||||
});
|
|
||||||
},
|
},
|
||||||
|
|
||||||
addFavorite: function(appId) {
|
addFavorite: function(appId) {
|
||||||
@ -119,11 +116,9 @@ const AppFavorites = new Lang.Class({
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
Main.overview.setMessage(_("%s has been removed from your favorites.").format(app.get_name()),
|
Main.overview.setMessage(_("%s has been removed from your favorites.").format(app.get_name()),
|
||||||
{ forFeedback: true,
|
Lang.bind(this, function () {
|
||||||
undoCallback: Lang.bind(this, function () {
|
|
||||||
this._addFavorite(appId, pos);
|
this._addFavorite(appId, pos);
|
||||||
})
|
}));
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(AppFavorites.prototype);
|
Signals.addSignalMethods(AppFavorites.prototype);
|
||||||
|
93
js/ui/centerLayout.js
Normal file
93
js/ui/centerLayout.js
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
|
|
||||||
|
const Lang = imports.lang;
|
||||||
|
const Clutter = imports.gi.Clutter;
|
||||||
|
const St = imports.gi.St;
|
||||||
|
|
||||||
|
function connectLayoutManager(layoutManager, styleChanged) {
|
||||||
|
let widget, styleChangedId;
|
||||||
|
|
||||||
|
function _styleChanged() {
|
||||||
|
let themeNode = widget.get_theme_node();
|
||||||
|
styleChanged(themeNode, widget);
|
||||||
|
}
|
||||||
|
|
||||||
|
function actorChanged() {
|
||||||
|
if (widget) {
|
||||||
|
widget.disconnect(styleChangedId);
|
||||||
|
styleChangedId = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
let actor = layoutManager.get_actor();
|
||||||
|
if (actor && actor instanceof St.Widget) {
|
||||||
|
widget = actor;
|
||||||
|
styleChangedId = widget.connect('style-changed', _styleChanged);
|
||||||
|
_styleChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
layoutManager.connect('notify::actor', actorChanged);
|
||||||
|
return layoutManager;
|
||||||
|
}
|
||||||
|
|
||||||
|
function connectSpacing(layoutManager) {
|
||||||
|
return connectLayoutManager(layoutManager, function(themeNode, widget) {
|
||||||
|
layoutManager.spacing = themeNode.get_length('spacing');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const CenterLayout = new Lang.Class({
|
||||||
|
Name: 'CenterLayout',
|
||||||
|
Extends: Clutter.BoxLayout,
|
||||||
|
|
||||||
|
vfunc_allocate: function(container, box, flags) {
|
||||||
|
let rtl = container.get_text_direction() == Clutter.TextDirection.RTL;
|
||||||
|
|
||||||
|
let availWidth = box.x2 - box.x1;
|
||||||
|
let availHeight = box.y2 - box.y1;
|
||||||
|
|
||||||
|
// Assume that these are the first three widgets and they are all visible.
|
||||||
|
let [left, center, right] = container.get_children();
|
||||||
|
|
||||||
|
// Only support horizontal layouts for now.
|
||||||
|
let [centerMinWidth, centerNaturalWidth] = center.get_preferred_width(availWidth);
|
||||||
|
|
||||||
|
let sideWidth = (availWidth - centerNaturalWidth) / 2;
|
||||||
|
|
||||||
|
let childBox = new Clutter.ActorBox();
|
||||||
|
childBox.y1 = box.y1;
|
||||||
|
childBox.y2 = box.y1 + availHeight;
|
||||||
|
|
||||||
|
if (left) {
|
||||||
|
let [leftMinWidth, leftNaturalWidth] = left.get_preferred_width(availWidth);
|
||||||
|
let leftSide = Math.min(Math.floor(sideWidth), leftNaturalWidth);
|
||||||
|
if (rtl) {
|
||||||
|
childBox.x1 = availWidth - leftSide;
|
||||||
|
childBox.x2 = availWidth;
|
||||||
|
} else {
|
||||||
|
childBox.x1 = 0;
|
||||||
|
childBox.x2 = leftSide;
|
||||||
|
}
|
||||||
|
childBox.x1 += box.x1;
|
||||||
|
left.allocate(childBox, flags);
|
||||||
|
}
|
||||||
|
|
||||||
|
childBox.x1 = box.x1 + Math.ceil(sideWidth);
|
||||||
|
childBox.x2 = childBox.x1 + centerNaturalWidth;
|
||||||
|
center.allocate(childBox, flags);
|
||||||
|
|
||||||
|
if (right) {
|
||||||
|
let [rightMinWidth, rightNaturalWidth] = right.get_preferred_width(availWidth);
|
||||||
|
let rightSide = Math.min(Math.floor(sideWidth), rightNaturalWidth);
|
||||||
|
if (rtl) {
|
||||||
|
childBox.x1 = 0;
|
||||||
|
childBox.x2 = rightSide;
|
||||||
|
} else {
|
||||||
|
childBox.x1 = availWidth - rightSide;
|
||||||
|
childBox.x2 = availWidth;
|
||||||
|
}
|
||||||
|
childBox.x1 += box.x1;
|
||||||
|
right.allocate(childBox, flags);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
@ -1,647 +0,0 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
|
||||||
|
|
||||||
const Clutter = imports.gi.Clutter;
|
|
||||||
const Gdk = imports.gi.Gdk;
|
|
||||||
const GLib = imports.gi.GLib;
|
|
||||||
const Gio = imports.gi.Gio;
|
|
||||||
const Lang = imports.lang;
|
|
||||||
const Meta = imports.gi.Meta;
|
|
||||||
const Shell = imports.gi.Shell;
|
|
||||||
const St = imports.gi.St;
|
|
||||||
|
|
||||||
const Main = imports.ui.main;
|
|
||||||
const MessageTray = imports.ui.messageTray;
|
|
||||||
const ShellMountOperation = imports.ui.shellMountOperation;
|
|
||||||
const Tweener = imports.ui.tweener;
|
|
||||||
const Util = imports.misc.util;
|
|
||||||
|
|
||||||
const INTERFACE_SETTINGS = 'org.gnome.desktop.interface';
|
|
||||||
const POWER_SETTINGS = 'org.gnome.settings-daemon.plugins.power';
|
|
||||||
const XSETTINGS_SETTINGS = 'org.gnome.settings-daemon.plugins.xsettings';
|
|
||||||
const TOUCHPAD_SETTINGS = 'org.gnome.settings-daemon.peripherals.touchpad';
|
|
||||||
const KEYBINDING_SETTINGS = 'org.gnome.settings-daemon.plugins.media-keys';
|
|
||||||
const CUSTOM_KEYBINDING_SETTINGS = 'org.gnome.settings-daemon.plugins.media-keys.custom-keybinding';
|
|
||||||
const A11Y_SETTINGS = 'org.gnome.desktop.a11y.applications';
|
|
||||||
const MAGNIFIER_SETTINGS = 'org.gnome.desktop.a11y.magnifier';
|
|
||||||
const INPUT_SOURCE_SETTINGS = 'org.gnome.desktop.input-sources';
|
|
||||||
|
|
||||||
const MediaKeysInterface = <interface name='org.gnome.SettingsDaemon.MediaKeys'>
|
|
||||||
<method name='GrabMediaPlayerKeys'>
|
|
||||||
<arg name='application' direction='in' type='s'/>
|
|
||||||
<arg name='time' direction='in' type='u'/>
|
|
||||||
</method>
|
|
||||||
<method name='ReleaseMediaPlayerKeys'>
|
|
||||||
<arg name='application' direction='in' type='s'/>
|
|
||||||
</method>
|
|
||||||
<signal name='MediaPlayerKeyPressed'>
|
|
||||||
<arg name='application' type='s'/>
|
|
||||||
<arg name='key' type='s'/>
|
|
||||||
</signal>
|
|
||||||
</interface>;
|
|
||||||
|
|
||||||
/* [ actionName, setting, hardcodedKeysym, overviewOnly, args ] */
|
|
||||||
/* (overviewOnly means that the keybinding is handled when the shell is not
|
|
||||||
modal, or when the overview is active, but not when other modal operations
|
|
||||||
are active; otherwise the keybinding is always handled) */
|
|
||||||
const DEFAULT_KEYBINDINGS = [
|
|
||||||
[ 'doTouchpadToggle', null, 'XF86TouchpadToggle', false ],
|
|
||||||
[ 'doTouchpadSet', null, 'XF86TouchpadOn', false, [ true ] ],
|
|
||||||
[ 'doTouchpadSet', null, 'XF86TouchpadOff', false, [ false ] ],
|
|
||||||
[ 'doMute', 'volume-mute', null, false, [ false ] ],
|
|
||||||
[ 'doVolumeAdjust', 'volume-down', null, false, [ Clutter.ScrollDirection.DOWN, false ] ],
|
|
||||||
[ 'doVolumeAdjust', 'volume-up', null, false, [ Clutter.ScrollDirection.UP, false ] ],
|
|
||||||
[ 'doMute', null, '<Alt>XF86AudioMute', false, [ true ] ],
|
|
||||||
[ 'doVolumeAdjust', null, '<Alt>XF86AudioLowerVolume', false, [ Clutter.ScrollDirection.DOWN, true ] ],
|
|
||||||
[ 'doVolumeAdjust', null, '<Alt>XF86AudioRaiseVolume', false, [ Clutter.ScrollDirection.UP, true ] ],
|
|
||||||
[ 'doLogout', 'logout', null, true ],
|
|
||||||
[ 'doEject', 'eject', null, false ],
|
|
||||||
[ 'doHome', 'home', null, true ],
|
|
||||||
[ 'doLaunchMimeHandler', 'media', null, true, [ 'application/x-vorbis+ogg' ] ],
|
|
||||||
[ 'doLaunchApp', 'calculator', null, true, [ 'gcalcltool.desktop' ] ],
|
|
||||||
[ 'doLaunchApp', 'search', null, true, [ 'tracker-needle.desktop' ] ],
|
|
||||||
[ 'doLaunchMimeHandler', 'email', null, true, [ 'x-scheme-handler/mailto' ] ],
|
|
||||||
[ 'doScreensaver', 'screensaver', null, true ],
|
|
||||||
[ 'doScreensaver', null, 'XF86ScreenSaver', true ],
|
|
||||||
[ 'doLaunchApp', 'help', null, true, [ 'yelp.desktop' ] ],
|
|
||||||
[ 'doSpawn', 'screenshot', null, true, [ ['gnome-screenshot'] ] ],
|
|
||||||
[ 'doSpawn', 'window-screenshot', null, true, [ ['gnome-screenshot', '--window'] ] ],
|
|
||||||
[ 'doSpawn', 'area-screenshot', null, true, [ ['gnome-screenshot', '--area'] ] ],
|
|
||||||
[ 'doSpawn', 'screenshot-clip', null, true, [ ['gnome-screenshot', '--clipboard'] ] ],
|
|
||||||
[ 'doSpawn', 'window-screenshot-clip', null, true, [ ['gnome-screenshot', '--window', '--clipboard'] ] ],
|
|
||||||
[ 'doSpawn', 'area-screenshot-clip', null, true, [ ['gnome-screenshot', '--area', '--clipboard'] ] ],
|
|
||||||
[ 'doLaunchMimeHandler', 'www', null, true, [ 'x-scheme-handler/http' ] ],
|
|
||||||
[ 'doMediaKey', 'play', null, true, [ 'Play' ] ],
|
|
||||||
[ 'doMediaKey', 'pause', null, true, [ 'Pause' ] ],
|
|
||||||
[ 'doMediaKey', 'stop', null, true, [ 'Stop' ] ],
|
|
||||||
[ 'doMediaKey', 'previous', null, true, [ 'Previous' ] ],
|
|
||||||
[ 'doMediaKey', 'next', null, true, [ 'Next' ] ],
|
|
||||||
[ 'doMediaKey', null, 'XF86AudioRewind', true, [ 'Rewind' ] ],
|
|
||||||
[ 'doMediaKey', null, 'XF86AudioForward', true, [ 'FastForward' ] ],
|
|
||||||
[ 'doMediaKey', null, 'XF86AudioRepeat', true, [ 'Repeat' ] ],
|
|
||||||
[ 'doMediaKey', null, 'XF86AudioRandomPlay', true, [ 'Shuffle' ] ],
|
|
||||||
[ 'doXRandRAction', null, '<Super>p', false, [ 'VideoModeSwitch' ] ],
|
|
||||||
/* Key code of the XF86Display key (Fn-F7 on Thinkpads, Fn-F4 on HP machines, etc.) */
|
|
||||||
[ 'doXRandRAction', null, 'XF86Display', false, [ 'VideoModeSwitch' ] ],
|
|
||||||
/* Key code of the XF86RotateWindows key (present on some tablets) */
|
|
||||||
[ 'doXRandRAction', null, 'XF86RotateWindows', false, [ 'Rotate' ] ],
|
|
||||||
[ 'doA11yAction', 'magnifier', null, true, [ 'screen-magnifier-enabled' ] ],
|
|
||||||
[ 'doA11yAction', 'screenreader', null, true, [ 'screen-reader-enabled' ] ],
|
|
||||||
[ 'doA11yAction', 'on-screen-keyboard', null, true, [ 'screen-keyboard-enabled' ] ],
|
|
||||||
[ 'doTextSize', 'increase-text-size', null, true, [ 1 ] ],
|
|
||||||
[ 'doTextSize', 'decrease-text-size', null, true, [ -1 ] ],
|
|
||||||
[ 'doToggleContrast', 'toggle-contrast', null, true ],
|
|
||||||
[ 'doMagnifierZoom', 'magnifier-zoom-in', null, true, [ 1 ] ],
|
|
||||||
[ 'doMagnifierZoom', 'magnifier-zoom-out', null, true, [ -1 ] ],
|
|
||||||
[ 'doPowerAction', null, 'XF86PowerOff', true, [ 'button-power' ] ],
|
|
||||||
/* the kernel / Xorg names really are like this... */
|
|
||||||
[ 'doPowerAction', null, 'XF86Suspend', false, [ 'button-sleep' ] ],
|
|
||||||
[ 'doPowerAction', null, 'XF86Sleep', false, [ 'button-suspend' ] ],
|
|
||||||
[ 'doPowerAction', null, 'XF86Hibernate', false, [ 'button-hibernate' ] ],
|
|
||||||
[ 'doBrightness', null, 'XF86MonBrightnessUp', false, [ 'Screen', 'StepUp' ] ],
|
|
||||||
[ 'doBrightness', null, 'XF86MonBrightnessDown', false, [ 'Screen', 'StepDown' ] ],
|
|
||||||
[ 'doBrightness', null, 'XF86KbdBrightnessUp', false, [ 'Keyboard', 'StepUp' ] ],
|
|
||||||
[ 'doBrightness', null, 'XF86KbdBrightnessDown', false, [ 'Keyboard', 'StepDown' ] ],
|
|
||||||
[ 'doBrightnessToggle', null, 'XF86KbdLightOnOff', false, ],
|
|
||||||
[ 'doInputSource', 'switch-input-source', null, false, [ +1 ] ],
|
|
||||||
[ 'doInputSource', 'switch-input-source-backward', null, false, [ -1 ] ],
|
|
||||||
[ 'doLaunchApp', null, 'XF86Battery', true, [ 'gnome-power-statistics.desktop' ] ]
|
|
||||||
];
|
|
||||||
|
|
||||||
var osdWin;
|
|
||||||
const OSDWindow = new Lang.Class({
|
|
||||||
Name: 'OSDWindow',
|
|
||||||
|
|
||||||
FADE_TIMEOUT: 1500,
|
|
||||||
FADE_DURATION: 100,
|
|
||||||
|
|
||||||
_init: function(iconName, value) {
|
|
||||||
/* assume 130x130 on a 640x480 display and scale from there */
|
|
||||||
let monitor = Main.layoutManager.primaryMonitor;
|
|
||||||
let scalew = monitor.width / 640.0;
|
|
||||||
let scaleh = monitor.height / 480.0;
|
|
||||||
let scale = Math.min(scalew, scaleh);
|
|
||||||
let size = 130 * Math.max(1, scale);
|
|
||||||
|
|
||||||
this.actor = new St.BoxLayout({ style_class: 'osd-window',
|
|
||||||
vertical: true,
|
|
||||||
reactive: false,
|
|
||||||
visible: false,
|
|
||||||
width: size,
|
|
||||||
height: size,
|
|
||||||
});
|
|
||||||
|
|
||||||
this._icon = new St.Icon({ icon_name: iconName,
|
|
||||||
icon_size: size / 2,
|
|
||||||
});
|
|
||||||
this.actor.add(this._icon, { expand: true,
|
|
||||||
x_align: St.Align.MIDDLE,
|
|
||||||
y_align: St.Align.MIDDLE });
|
|
||||||
|
|
||||||
this._value = value;
|
|
||||||
this._progressBar = new St.DrawingArea({ style_class: 'osd-progress-bar' });
|
|
||||||
this._progressBar.connect('repaint', Lang.bind(this, this._drawProgress));
|
|
||||||
this.actor.add(this._progressBar, { expand: true, x_fill: true, y_fill: false });
|
|
||||||
this._progressBar.visible = value !== undefined;
|
|
||||||
|
|
||||||
Main.layoutManager.addChrome(this.actor);
|
|
||||||
|
|
||||||
/* Position in the middle of primary monitor */
|
|
||||||
let [width, height] = this.actor.get_size();
|
|
||||||
this.actor.x = ((monitor.width - width) / 2) + monitor.x;
|
|
||||||
this.actor.y = monitor.y + (monitor.height / 2) + (monitor.height / 2 - height) / 2;
|
|
||||||
},
|
|
||||||
|
|
||||||
show: function() {
|
|
||||||
this.actor.show();
|
|
||||||
Tweener.addTween(this.actor,
|
|
||||||
{ opacity: 255,
|
|
||||||
time: this.FADE_DURATION / 1000,
|
|
||||||
transition: 'easeInQuad' });
|
|
||||||
|
|
||||||
if (this._timeoutId)
|
|
||||||
GLib.source_remove(this._timeoutId);
|
|
||||||
|
|
||||||
this._timeoutId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, this.FADE_TIMEOUT, Lang.bind(this, this.hide));
|
|
||||||
},
|
|
||||||
|
|
||||||
hide: function() {
|
|
||||||
Tweener.addTween(this.actor,
|
|
||||||
{ opacity: 0,
|
|
||||||
time: this.FADE_DURATION / 1000,
|
|
||||||
transition: 'easeOutQuad',
|
|
||||||
onComplete: function() {
|
|
||||||
this.actor.destroy();
|
|
||||||
this.actor = null;
|
|
||||||
osdWin = null;
|
|
||||||
},
|
|
||||||
onCompleteScope: this });
|
|
||||||
|
|
||||||
return false;
|
|
||||||
},
|
|
||||||
|
|
||||||
setIcon: function(name) {
|
|
||||||
this._icon.icon_name = name;
|
|
||||||
},
|
|
||||||
|
|
||||||
setValue: function(value) {
|
|
||||||
if (value == this._value)
|
|
||||||
return;
|
|
||||||
|
|
||||||
this._value = value;
|
|
||||||
this._progressBar.visible = value !== undefined;
|
|
||||||
this._progressBar.queue_repaint();
|
|
||||||
},
|
|
||||||
|
|
||||||
_drawProgress: function(area) {
|
|
||||||
let cr = area.get_context();
|
|
||||||
|
|
||||||
let themeNode = this.actor.get_theme_node();
|
|
||||||
let color = themeNode.get_foreground_color();
|
|
||||||
Clutter.cairo_set_source_color(cr, color);
|
|
||||||
|
|
||||||
let [width, height] = area.get_surface_size();
|
|
||||||
width = width * this._value;
|
|
||||||
|
|
||||||
cr.moveTo(0,0);
|
|
||||||
cr.lineTo(width, 0);
|
|
||||||
cr.lineTo(width, height);
|
|
||||||
cr.lineTo(0, height);
|
|
||||||
cr.fill();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
function showOSD(icon, value) {
|
|
||||||
if (osdWin) {
|
|
||||||
osdWin.setIcon(icon);
|
|
||||||
osdWin.setValue(value);
|
|
||||||
} else {
|
|
||||||
osdWin = new OSDWindow(icon, value);
|
|
||||||
}
|
|
||||||
|
|
||||||
osdWin.show();
|
|
||||||
}
|
|
||||||
|
|
||||||
const MediaKeysGrabber = new Lang.Class({
|
|
||||||
Name: 'MediaKeysGrabber',
|
|
||||||
|
|
||||||
_init: function() {
|
|
||||||
this._dbusImpl = Gio.DBusExportedObject.wrapJSObject(MediaKeysInterface, this);
|
|
||||||
this._apps = [];
|
|
||||||
},
|
|
||||||
|
|
||||||
enable: function() {
|
|
||||||
this._dbusImpl.export(Gio.DBus.session, '/org/gnome/SettingsDaemon/MediaKeys');
|
|
||||||
},
|
|
||||||
|
|
||||||
disable: function() {
|
|
||||||
this._dbusImpl.unexport();
|
|
||||||
},
|
|
||||||
|
|
||||||
GrabMediaPlayerKeysAsync: function(parameters, invocation) {
|
|
||||||
let [appName, time] = parameters;
|
|
||||||
|
|
||||||
/* I'm not sure of this code, but it is in gnome-settings-daemon
|
|
||||||
(letting alone that the introspection is wrong in glib...)
|
|
||||||
*/
|
|
||||||
if (time == Gdk.CURRENT_TIME) {
|
|
||||||
let tv = new GLib.TimeVal;
|
|
||||||
GLib.get_current_time(tv);
|
|
||||||
time = tv.tv_sec * 1000 + tv.tv_usec / 1000;
|
|
||||||
}
|
|
||||||
|
|
||||||
let pos = -1;
|
|
||||||
for (let i = 0; i < this._apps.length; i++) {
|
|
||||||
if (this._apps[i].appName == appName) {
|
|
||||||
pos = i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (pos != -1)
|
|
||||||
this._freeMediaPlayer(pos);
|
|
||||||
|
|
||||||
let app = {
|
|
||||||
appName: appName,
|
|
||||||
name: invocation.get_sender(),
|
|
||||||
time: time,
|
|
||||||
watchId: Gio.DBus.session.watch_name(invocation.get_sender(),
|
|
||||||
Gio.BusNameWatcherFlags.NONE,
|
|
||||||
null,
|
|
||||||
Lang.bind(this, this._onNameVanished)),
|
|
||||||
};
|
|
||||||
Util.insertSorted(this._apps, app, function(a, b) {
|
|
||||||
return b.time-a.time;
|
|
||||||
});
|
|
||||||
|
|
||||||
invocation.return_value(GLib.Variant.new('()', []));
|
|
||||||
},
|
|
||||||
|
|
||||||
ReleaseMediaPlayerAsync: function(parameters, invocation) {
|
|
||||||
let name = invocation.get_sender();
|
|
||||||
let [appName] = parameters;
|
|
||||||
|
|
||||||
let pos = -1;
|
|
||||||
for (let i = 0; i < this._apps.length; i++) {
|
|
||||||
if (this._apps[i].appName == appName) {
|
|
||||||
pos = i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (pos == -1) {
|
|
||||||
for (let i = 0; i < this._apps.length; i++) {
|
|
||||||
if (this._apps[i].name == name) {
|
|
||||||
pos = i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (pos != -1)
|
|
||||||
this._freeMediaPlayer(pos);
|
|
||||||
|
|
||||||
invocation.return_value(GLib.Variant.new('()', []));
|
|
||||||
},
|
|
||||||
|
|
||||||
_freeMediaPlayer: function(pos) {
|
|
||||||
let app = this._apps[pos];
|
|
||||||
Gio.bus_unwatch_name(app.watchId)
|
|
||||||
|
|
||||||
this._apps.splice(pos, 1);
|
|
||||||
},
|
|
||||||
|
|
||||||
mediaKeyPressed: function(key) {
|
|
||||||
if (this._apps.length == 0) {
|
|
||||||
showOSD('action-unavailable-symbolic');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
let app = this._apps[0];
|
|
||||||
Gio.DBus.session.emit_signal(app.name,
|
|
||||||
'/org/gnome/SettingsDaemon/MediaKeys',
|
|
||||||
'org.gnome.SettingsDaemon.MediaKeys',
|
|
||||||
'MediaPlayerKeyPressed',
|
|
||||||
GLib.Variant.new('(ss)', [app.appName || '',
|
|
||||||
key]));
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
const MediaKeysManager = new Lang.Class({
|
|
||||||
Name: 'MediaKeysManager',
|
|
||||||
|
|
||||||
_init: function() {
|
|
||||||
this._a11yControl = Main.panel.statusArea.a11y;
|
|
||||||
this._volumeControl = Main.panel.statusArea.volume;
|
|
||||||
this._userMenu = Main.panel.statusArea.userMenu;
|
|
||||||
this._mediaPlayerKeys = new MediaKeysGrabber();
|
|
||||||
|
|
||||||
this._keybindingSettings = new Gio.Settings({ schema: KEYBINDING_SETTINGS });
|
|
||||||
},
|
|
||||||
|
|
||||||
enable: function() {
|
|
||||||
for (let i = 0; i < DEFAULT_KEYBINDINGS.length; i++) {
|
|
||||||
let [action, setting, keyval, overviewOnly, args] = DEFAULT_KEYBINDINGS[i];
|
|
||||||
let func = this[action];
|
|
||||||
if (!func) {
|
|
||||||
log('Keybinding action %s is missing'.format(action));
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
let name = setting ? setting : 'media-keys-keybindings-%d'.format(i);
|
|
||||||
let ok;
|
|
||||||
func = Util.wrapKeybinding(Lang.bind.apply(null, [this, func].concat(args)), overviewOnly);
|
|
||||||
if (setting)
|
|
||||||
ok = global.display.add_keybinding(setting, this._keybindingSettings,
|
|
||||||
Meta.KeyBindingFlags.BUILTIN |
|
|
||||||
Meta.KeyBindingFlags.IS_SINGLE |
|
|
||||||
Meta.KeyBindingFlags.HANDLE_WHEN_GRABBED, func);
|
|
||||||
else
|
|
||||||
ok = global.display.add_grabbed_key(name, keyval,
|
|
||||||
Meta.KeyBindingFlags.HANDLE_WHEN_GRABBED, func);
|
|
||||||
|
|
||||||
if (!ok)
|
|
||||||
log('Installing keybinding %s failed'.format(name));
|
|
||||||
}
|
|
||||||
|
|
||||||
this._customKeybindings = [];
|
|
||||||
this._changedId = this._keybindingSettings.connect('changed::custom-keybindings',
|
|
||||||
Lang.bind(this, this._reloadCustomKeybindings));
|
|
||||||
this._reloadCustomKeybindings();
|
|
||||||
|
|
||||||
this._mediaPlayerKeys.enable();
|
|
||||||
},
|
|
||||||
|
|
||||||
disable: function() {
|
|
||||||
for (let i = 0; i < DEFAULT_KEYBINDINGS.length; i++) {
|
|
||||||
let [action, setting, keyval, overviewOnly, args] = DEFAULT_KEYBINDINGS[i];
|
|
||||||
|
|
||||||
let name = setting ? setting : 'media-keys-keybindings-%d'.format(i);
|
|
||||||
if (setting)
|
|
||||||
global.display.remove_keybinding(setting, this._keybindingSettings);
|
|
||||||
else
|
|
||||||
global.display.remove_grabbed_key(name);
|
|
||||||
}
|
|
||||||
|
|
||||||
this._clearCustomKeybindings();
|
|
||||||
this._keybindingSettings.disconnect(this._changedId);
|
|
||||||
|
|
||||||
this._mediaPlayerKeys.disable();
|
|
||||||
},
|
|
||||||
|
|
||||||
_clearCustomKeybindings: function() {
|
|
||||||
for (let i = 0; i < this._customKeybindings.length; i++)
|
|
||||||
global.display.remove_keybinding('binding', this._customKeybindings[i]);
|
|
||||||
|
|
||||||
this._customKeybindings = [];
|
|
||||||
},
|
|
||||||
|
|
||||||
_reloadCustomKeybindings: function() {
|
|
||||||
this._clearCustomKeybindings();
|
|
||||||
|
|
||||||
let paths = this._keybindingSettings.get_strv('custom-keybindings');
|
|
||||||
for (let i = 0; i < paths.length; i++) {
|
|
||||||
let setting = new Gio.Settings({ schema: CUSTOM_KEYBINDING_SETTINGS,
|
|
||||||
path: paths[i] });
|
|
||||||
let func = Util.wrapKeybinding(Lang.bind(this, this.doCustom, setting), true);
|
|
||||||
|
|
||||||
global.display.add_keybinding('binding', setting,
|
|
||||||
Meta.KeyBindingFlags.IS_SINGLE |
|
|
||||||
Meta.KeyBindingFlags.HANDLE_WHEN_GRABBED, func);
|
|
||||||
this._customKeybindings.push(setting);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
doCustom: function(display, screen, window, binding, settings) {
|
|
||||||
let command = settings.get_string('command');
|
|
||||||
Util.spawnCommandLine(command);
|
|
||||||
},
|
|
||||||
|
|
||||||
doTouchpadToggle: function(display, screen, window, binding) {
|
|
||||||
let settings = new Gio.Settings({ schema: TOUCHPAD_SETTINGS });
|
|
||||||
let enabled = settings.get_boolean('touchpad-enabled');
|
|
||||||
|
|
||||||
this.doTouchpadSet(display, screen, window, binding, !enabled);
|
|
||||||
settings.set_boolean(!enabled);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doTouchpadSet: function(display, screen, window, binding, enabled) {
|
|
||||||
showOSD(enabled ? 'input-touchpad-symbolic' : 'touchpad-disabled-symbolic');
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doMute: function(display, screen, window, binding, quiet) {
|
|
||||||
let [icon, value] = this._volumeControl.volumeMenu.toggleMute(quiet);
|
|
||||||
showOSD(icon, value);
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doVolumeAdjust: function(display, screen, window, binding, direction, quiet) {
|
|
||||||
let [icon, value] = this._volumeControl.volumeMenu.scroll(direction, quiet);
|
|
||||||
showOSD(icon, value);
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doLogout: function(display, screen, window, binding) {
|
|
||||||
this._userMenu.logOut();
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doEject: function(display, screen, window, binding) {
|
|
||||||
let volumeMonitor = Gio.VolumeMonitor.get();
|
|
||||||
|
|
||||||
let drives = volumeMonitor.get_connected_drives();
|
|
||||||
let score = 0, drive;
|
|
||||||
for (let i = 0; i < drives.length; i++) {
|
|
||||||
if (!drives[i].can_eject())
|
|
||||||
continue;
|
|
||||||
if (!drives[i].is_media_removable())
|
|
||||||
continue;
|
|
||||||
if (score < 1) {
|
|
||||||
drive = drives[i];
|
|
||||||
score = 1;
|
|
||||||
}
|
|
||||||
if (!drives[i].has_media())
|
|
||||||
continue;
|
|
||||||
if (score < 2) {
|
|
||||||
drive = drives[i];
|
|
||||||
score = 2;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
showOSD('media-eject-custom-symbolic');
|
|
||||||
|
|
||||||
if (!drive)
|
|
||||||
return true;
|
|
||||||
|
|
||||||
let mountOp = new ShellMountOperation.ShellMountOperation(drive);
|
|
||||||
drive.eject_with_operation(Gio.MountUnmountFlags.FORCE,
|
|
||||||
mountOp.mountOp, null, null);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doHome: function() {
|
|
||||||
let homeFile = Gio.file_new_for_path (GLib.get_home_dir());
|
|
||||||
let homeUri = homeFile.get_uri();
|
|
||||||
Gio.app_info_launch_default_for_uri(homeUri, null);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doLaunchMimeHandler: function(display, screen, window, binding, mimeType) {
|
|
||||||
let gioApp = Gio.AppInfo.get_default_for_type(mimeType, false);
|
|
||||||
if (gioApp != null) {
|
|
||||||
let app = Shell.AppSystem.get_default().lookup_app(gioApp.get_id());
|
|
||||||
app.open_new_window(-1);
|
|
||||||
} else {
|
|
||||||
log('Could not find default application for \'%s\' mime-type'.format(mimeType));
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doLaunchApp: function(display, screen, window, binding, appId) {
|
|
||||||
let app = Shell.AppSystem.get_default().lookup_app(appId);
|
|
||||||
app.open_new_window(-1);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doScreensaver: function() {
|
|
||||||
// FIXME: handled in house, to the screenshield!
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doSpawn: function(display, screen, window, binding, argv) {
|
|
||||||
Util.spawn(argv);
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
doMediaKey: function(display, screen, window, binding, key) {
|
|
||||||
this._mediaPlayerKeys.mediaKeyPressed(key);
|
|
||||||
},
|
|
||||||
|
|
||||||
_onXRandRFinished: function(connection, result) {
|
|
||||||
connection.call_finish(result);
|
|
||||||
this._XRandRCancellable = null;
|
|
||||||
},
|
|
||||||
|
|
||||||
doXRandRAction: function(display, screen, window, binding, action) {
|
|
||||||
if (this._XRandRCancellable)
|
|
||||||
this._XRandRCancellable.cancel();
|
|
||||||
|
|
||||||
this._XRandRCancellable = new Gio.Cancellable();
|
|
||||||
Gio.DBus.session.call('org.gnome.SettingsDaemon',
|
|
||||||
'/org/gnome/SettingsDaemon/XRANDR',
|
|
||||||
'org.gnome.SettingsDaemon.XRANDR_2',
|
|
||||||
action,
|
|
||||||
GLib.Variant.new('(x)', [global.get_current_time()]),
|
|
||||||
null, /* reply type */
|
|
||||||
Gio.DBusCallFlags.NONE,
|
|
||||||
-1,
|
|
||||||
this._XRandRCancellable,
|
|
||||||
Lang.bind(this, this._onXRandRFinished));
|
|
||||||
},
|
|
||||||
|
|
||||||
doA11yAction: function(display, screen, window, binding, key) {
|
|
||||||
let settings = new Gio.Settings({ schema: A11Y_SETTINGS });
|
|
||||||
let enabled = settings.get_boolean(key);
|
|
||||||
settings.set_boolean(key, !enabled);
|
|
||||||
},
|
|
||||||
|
|
||||||
doTextSize: function(display, screen, window, binding, multiplier) {
|
|
||||||
// Same values used in the Seeing tab of the Universal Access panel
|
|
||||||
const FACTORS = [ 0.75, 1.0, 1.25, 1.5 ];
|
|
||||||
|
|
||||||
// Figure out the current DPI scaling factor
|
|
||||||
let settings = new Gio.Settings({ schema: INTERFACE_SETTINGS });
|
|
||||||
let factor = settings.get_double('text-scaling-factor');
|
|
||||||
factor += multiplier * 0.25;
|
|
||||||
|
|
||||||
/* Try to find a matching value */
|
|
||||||
let distance = 1e6;
|
|
||||||
let best = 1.0;
|
|
||||||
for (let i = 0; i < FACTORS.length; i++) {
|
|
||||||
let d = Math.abs(factor - FACTORS[i]);
|
|
||||||
if (d < distance) {
|
|
||||||
best = factors[i];
|
|
||||||
distance = d;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (best == 1.0)
|
|
||||||
settings.reset('text-scaling-factor');
|
|
||||||
else
|
|
||||||
settings.set_double('text-scaling-factor', best);
|
|
||||||
},
|
|
||||||
|
|
||||||
doToggleContrast: function(display, screen, window, binding) {
|
|
||||||
this._a11yControl.toggleHighContrast();
|
|
||||||
},
|
|
||||||
|
|
||||||
doMagnifierZoom: function(display, screen, window, binding, offset) {
|
|
||||||
let settings = new Gio.Settings({ schema: MAGNIFIER_SETTINGS });
|
|
||||||
|
|
||||||
let value = settings.get_value('mag-factor');
|
|
||||||
value = Math.round(value + offset);
|
|
||||||
settings.set_value('mag-factor', value);
|
|
||||||
},
|
|
||||||
|
|
||||||
doPowerAction: function(display, screen, window, binding, action) {
|
|
||||||
let settings = new Gio.Settings({ schema: POWER_SETTINGS });
|
|
||||||
switch (settings.get_string(action)) {
|
|
||||||
case 'suspend':
|
|
||||||
this._userMenu.suspend();
|
|
||||||
break;
|
|
||||||
case 'interactive':
|
|
||||||
case 'shutdown':
|
|
||||||
this._userMenu.shutdown();
|
|
||||||
break;
|
|
||||||
case 'hibernate':
|
|
||||||
this._userMenu.hibernate();
|
|
||||||
break;
|
|
||||||
case 'blank':
|
|
||||||
case 'default':
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
_onBrightnessFinished: function(connection, result, kind) {
|
|
||||||
let [percentage] = connection.call_finish(result).deep_unpack();
|
|
||||||
|
|
||||||
let icon = kind == 'Keyboard' ? 'keyboard-brightness-symbolic' : 'display-brightness-symbolic';
|
|
||||||
showOSD(icon, percentage / 100);
|
|
||||||
},
|
|
||||||
|
|
||||||
doBrightness: function(display, screen, window, binding, kind, action) {
|
|
||||||
let iface = 'org.gnome.SettingsDaemon.Power.' + kind;
|
|
||||||
let objectPath = '/org/gnome/SettingsDaemon/Power';
|
|
||||||
|
|
||||||
Gio.DBus.session.call('org.gnome.SettingsDaemon',
|
|
||||||
objectPath, iface, action,
|
|
||||||
null, null, /* parameters, reply type */
|
|
||||||
Gio.DBusCallFlags.NONE, -1, null,
|
|
||||||
Lang.bind(this, this._onBrightnessFinished, kind));
|
|
||||||
},
|
|
||||||
|
|
||||||
doInputSource: function(display, screen, window, binding, offset) {
|
|
||||||
let settings = new Gio.Settings({ schema: INPUT_SOURCE_SETTINGS });
|
|
||||||
|
|
||||||
let current = settings.get_uint('current');
|
|
||||||
let max = settings.get_strv('sources').length - 1;
|
|
||||||
|
|
||||||
current += offset;
|
|
||||||
if (current < 0)
|
|
||||||
current = 0;
|
|
||||||
else if (current > max)
|
|
||||||
current = max;
|
|
||||||
|
|
||||||
settings.set_uint('current', current);
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
const Component = MediaKeysManager;
|
|
@ -52,8 +52,6 @@ const Recorder = new Lang.Class({
|
|||||||
Meta.disable_unredirect_for_screen(global.screen);
|
Meta.disable_unredirect_for_screen(global.screen);
|
||||||
recorder.record();
|
recorder.record();
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -771,19 +771,16 @@ const ChatNotification = new Lang.Class({
|
|||||||
this.emit('unfocused');
|
this.emit('unfocused');
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
this._oldMaxScrollAdjustment = 0;
|
||||||
this._createScrollArea();
|
this._createScrollArea();
|
||||||
this._lastGroup = null;
|
this._lastGroup = null;
|
||||||
this._lastGroupActor = null;
|
this._lastGroupActor = null;
|
||||||
|
|
||||||
// Keep track of the bottom position for the current adjustment and
|
|
||||||
// force a scroll to the bottom if things change while we were at the
|
|
||||||
// bottom
|
|
||||||
this._oldMaxScrollValue = this._scrollArea.vscroll.adjustment.value;
|
|
||||||
this._scrollArea.add_style_class_name('chat-notification-scrollview');
|
|
||||||
this._scrollArea.vscroll.adjustment.connect('changed', Lang.bind(this, function(adjustment) {
|
this._scrollArea.vscroll.adjustment.connect('changed', Lang.bind(this, function(adjustment) {
|
||||||
if (adjustment.value == this._oldMaxScrollValue)
|
let currentValue = adjustment.value + adjustment.page_size;
|
||||||
|
if (currentValue == this._oldMaxScrollAdjustment)
|
||||||
this.scrollTo(St.Side.BOTTOM);
|
this.scrollTo(St.Side.BOTTOM);
|
||||||
this._oldMaxScrollValue = Math.max(adjustment.lower, adjustment.upper - adjustment.page_size);
|
this._oldMaxScrollAdjustment = adjustment.upper;
|
||||||
}));
|
}));
|
||||||
|
|
||||||
this._inputHistory = new History.HistoryManager({ entry: this._responseEntry.clutter_text });
|
this._inputHistory = new History.HistoryManager({ entry: this._responseEntry.clutter_text });
|
||||||
@ -1136,7 +1133,7 @@ const AudioVideoNotification = new Lang.Class({
|
|||||||
this.parent(source, title, null, { customContent: true });
|
this.parent(source, title, null, { customContent: true });
|
||||||
this.setResident(true);
|
this.setResident(true);
|
||||||
|
|
||||||
this.addButton('reject', _("Decline"));
|
this.addButton('reject', _("Reject"));
|
||||||
/* translators: this is a button label (verb), not a noun */
|
/* translators: this is a button label (verb), not a noun */
|
||||||
this.addButton('answer', _("Answer"));
|
this.addButton('answer', _("Answer"));
|
||||||
|
|
||||||
|
@ -23,7 +23,8 @@ const DASH_ITEM_HOVER_TIMEOUT = 300;
|
|||||||
|
|
||||||
function getAppFromSource(source) {
|
function getAppFromSource(source) {
|
||||||
if (source instanceof AppDisplay.AppWellIcon) {
|
if (source instanceof AppDisplay.AppWellIcon) {
|
||||||
return source.app;
|
let appSystem = Shell.AppSystem.get_default();
|
||||||
|
return appSystem.lookup_app(source.getId());
|
||||||
} else if (source.metaWindow) {
|
} else if (source.metaWindow) {
|
||||||
let tracker = Shell.WindowTracker.get_default();
|
let tracker = Shell.WindowTracker.get_default();
|
||||||
return tracker.get_window_app(source.metaWindow);
|
return tracker.get_window_app(source.metaWindow);
|
||||||
@ -141,7 +142,6 @@ const DashItemContainer = new Lang.Class({
|
|||||||
|
|
||||||
setLabelText: function(text) {
|
setLabelText: function(text) {
|
||||||
this._labelText = text;
|
this._labelText = text;
|
||||||
this.child.accessible_name = text;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
hideLabel: function () {
|
hideLabel: function () {
|
||||||
@ -259,6 +259,7 @@ const ShowAppsIcon = new Lang.Class({
|
|||||||
|
|
||||||
this.setChild(this.toggleButton);
|
this.setChild(this.toggleButton);
|
||||||
this.setDragApp(null);
|
this.setDragApp(null);
|
||||||
|
this.toggleButton.label_actor = this.label;
|
||||||
},
|
},
|
||||||
|
|
||||||
_createIcon: function(size) {
|
_createIcon: function(size) {
|
||||||
@ -371,6 +372,9 @@ const Dash = new Lang.Class({
|
|||||||
this._maxHeight = -1;
|
this._maxHeight = -1;
|
||||||
this.iconSize = 64;
|
this.iconSize = 64;
|
||||||
this._shownInitially = false;
|
this._shownInitially = false;
|
||||||
|
this.visible = false;
|
||||||
|
this._hiddenX;
|
||||||
|
this._targetX;
|
||||||
|
|
||||||
this._dragPlaceholder = null;
|
this._dragPlaceholder = null;
|
||||||
this._dragPlaceholderPos = -1;
|
this._dragPlaceholderPos = -1;
|
||||||
@ -398,6 +402,7 @@ const Dash = new Lang.Class({
|
|||||||
function() {
|
function() {
|
||||||
if (this._maxHeight != this.actor.height)
|
if (this._maxHeight != this.actor.height)
|
||||||
this._queueRedisplay();
|
this._queueRedisplay();
|
||||||
|
if (this.actor.height > this._maxHeight)
|
||||||
this._maxHeight = this.actor.height;
|
this._maxHeight = this.actor.height;
|
||||||
}));
|
}));
|
||||||
|
|
||||||
@ -409,11 +414,11 @@ const Dash = new Lang.Class({
|
|||||||
AppFavorites.getAppFavorites().connect('changed', Lang.bind(this, this._queueRedisplay));
|
AppFavorites.getAppFavorites().connect('changed', Lang.bind(this, this._queueRedisplay));
|
||||||
this._appSystem.connect('app-state-changed', Lang.bind(this, this._queueRedisplay));
|
this._appSystem.connect('app-state-changed', Lang.bind(this, this._queueRedisplay));
|
||||||
|
|
||||||
Main.overview.connect('item-drag-begin',
|
Main.overview.connect('app-drag-begin',
|
||||||
Lang.bind(this, this._onDragBegin));
|
Lang.bind(this, this._onDragBegin));
|
||||||
Main.overview.connect('item-drag-end',
|
Main.overview.connect('app-drag-end',
|
||||||
Lang.bind(this, this._onDragEnd));
|
Lang.bind(this, this._onDragEnd));
|
||||||
Main.overview.connect('item-drag-cancelled',
|
Main.overview.connect('app-drag-cancelled',
|
||||||
Lang.bind(this, this._onDragCancelled));
|
Lang.bind(this, this._onDragCancelled));
|
||||||
Main.overview.connect('window-drag-begin',
|
Main.overview.connect('window-drag-begin',
|
||||||
Lang.bind(this, this._onDragBegin));
|
Lang.bind(this, this._onDragBegin));
|
||||||
@ -491,51 +496,32 @@ const Dash = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_createAppItem: function(app) {
|
_createAppItem: function(app) {
|
||||||
let appIcon = new AppDisplay.AppWellIcon(app,
|
let display = new AppDisplay.AppWellIcon(app,
|
||||||
{ setSizeManually: true,
|
{ setSizeManually: true,
|
||||||
showLabel: false });
|
showLabel: false });
|
||||||
appIcon._draggable.connect('drag-begin',
|
display._draggable.connect('drag-begin',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
appIcon.actor.opacity = 50;
|
display.actor.opacity = 50;
|
||||||
}));
|
}));
|
||||||
appIcon._draggable.connect('drag-end',
|
display._draggable.connect('drag-end',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
appIcon.actor.opacity = 255;
|
display.actor.opacity = 255;
|
||||||
}));
|
|
||||||
appIcon.connect('menu-state-changed',
|
|
||||||
Lang.bind(this, function(appIcon, opened) {
|
|
||||||
this._itemMenuStateChanged(item, opened);
|
|
||||||
}));
|
}));
|
||||||
|
|
||||||
let item = new DashItemContainer();
|
let item = new DashItemContainer();
|
||||||
item.setChild(appIcon.actor);
|
item.setChild(display.actor);
|
||||||
|
|
||||||
// Override default AppWellIcon label_actor, now the
|
|
||||||
// accessible_name is set at DashItemContainer.setLabelText
|
|
||||||
appIcon.actor.label_actor = null;
|
|
||||||
item.setLabelText(app.get_name());
|
item.setLabelText(app.get_name());
|
||||||
|
// Override default AppWellIcon label_actor
|
||||||
appIcon.icon.setIconSize(this.iconSize);
|
display.actor.label_actor = item.label;
|
||||||
|
display.icon.setIconSize(this.iconSize);
|
||||||
this._hookUpLabel(item);
|
this._hookUpLabel(item);
|
||||||
|
|
||||||
return item;
|
return item;
|
||||||
},
|
},
|
||||||
|
|
||||||
_itemMenuStateChanged: function(item, opened) {
|
|
||||||
// When the menu closes, it calls sync_hover, which means
|
|
||||||
// that the notify::hover handler does everything we need to.
|
|
||||||
if (opened) {
|
|
||||||
if (this._showLabelTimeoutId > 0) {
|
|
||||||
Mainloop.source_remove(this._showLabelTimeoutId);
|
|
||||||
this._showLabelTimeoutId = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
item.hideLabel();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
_onHover: function (item) {
|
_onHover: function (item) {
|
||||||
if (item.child.get_hover()) {
|
if (item.child.get_hover() && !item.child._delegate.isMenuUp) {
|
||||||
if (this._showLabelTimeoutId == 0) {
|
if (this._showLabelTimeoutId == 0) {
|
||||||
let timeout = this._labelShowing ? 0 : DASH_ITEM_HOVER_TIMEOUT;
|
let timeout = this._labelShowing ? 0 : DASH_ITEM_HOVER_TIMEOUT;
|
||||||
this._showLabelTimeoutId = Mainloop.timeout_add(timeout,
|
this._showLabelTimeoutId = Mainloop.timeout_add(timeout,
|
||||||
@ -564,6 +550,17 @@ const Dash = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_computeDashX: function() {
|
||||||
|
this._targetX = this.actor.get_x();
|
||||||
|
|
||||||
|
let rtl = (this.actor.get_text_direction() == Clutter.TextDirection.RTL);
|
||||||
|
|
||||||
|
if (rtl)
|
||||||
|
this._hiddenX = this._targetX + this.actor.width;
|
||||||
|
else
|
||||||
|
this._hiddenX = -this.actor.width;
|
||||||
|
},
|
||||||
|
|
||||||
_adjustIconSize: function() {
|
_adjustIconSize: function() {
|
||||||
// For the icon size, we only consider children which are "proper"
|
// For the icon size, we only consider children which are "proper"
|
||||||
// icons (i.e. ignoring drag placeholders) and which are not
|
// icons (i.e. ignoring drag placeholders) and which are not
|
||||||
@ -659,6 +656,8 @@ const Dash = new Lang.Class({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this._computeDashX();
|
||||||
},
|
},
|
||||||
|
|
||||||
_redisplay: function () {
|
_redisplay: function () {
|
||||||
@ -775,6 +774,7 @@ const Dash = new Lang.Class({
|
|||||||
// of items, to avoid all items zooming in at once
|
// of items, to avoid all items zooming in at once
|
||||||
if (!this._shownInitially) {
|
if (!this._shownInitially) {
|
||||||
this._shownInitially = true;
|
this._shownInitially = true;
|
||||||
|
this.visible = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -919,6 +919,34 @@ const Dash = new Lang.Class({
|
|||||||
}));
|
}));
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
},
|
||||||
|
|
||||||
|
show: function() {
|
||||||
|
if (this.visible)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this.visible = true;
|
||||||
|
|
||||||
|
this.actor.show();
|
||||||
|
Tweener.addTween(this.actor, { translation_x: this._targetX,
|
||||||
|
transition: 'easeOutQuad',
|
||||||
|
time: DASH_ANIMATION_TIME
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
hide: function() {
|
||||||
|
if (!this.visible)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this.visible = false;
|
||||||
|
|
||||||
|
Tweener.addTween(this.actor, { translation_x: this._hiddenX,
|
||||||
|
transition: 'easeOutQuad',
|
||||||
|
time: DASH_ANIMATION_TIME,
|
||||||
|
onComplete: Lang.bind(this, function () {
|
||||||
|
this.actor.hide();
|
||||||
|
})
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -105,7 +105,7 @@ const restartDialogContent = {
|
|||||||
endDescription: _("Restarting the system."),
|
endDescription: _("Restarting the system."),
|
||||||
confirmButtons: [{ signal: 'ConfirmedReboot',
|
confirmButtons: [{ signal: 'ConfirmedReboot',
|
||||||
label: C_("button", "Restart") }],
|
label: C_("button", "Restart") }],
|
||||||
iconName: 'view-refresh-symbolic',
|
iconName: 'system-shutdown-symbolic',
|
||||||
iconStyleClass: 'end-session-dialog-shutdown-icon'
|
iconStyleClass: 'end-session-dialog-shutdown-icon'
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -198,7 +198,11 @@ const IconGrid = new Lang.Class({
|
|||||||
|
|
||||||
_getPreferredHeight: function (grid, forWidth, alloc) {
|
_getPreferredHeight: function (grid, forWidth, alloc) {
|
||||||
let children = this._getVisibleChildren();
|
let children = this._getVisibleChildren();
|
||||||
let [nColumns, usedWidth] = this._computeLayout(forWidth);
|
let nColumns;
|
||||||
|
if (forWidth < 0)
|
||||||
|
nColumns = children.length;
|
||||||
|
else
|
||||||
|
nColumns = this._computeLayout(forWidth)[0];
|
||||||
let nRows;
|
let nRows;
|
||||||
if (nColumns > 0)
|
if (nColumns > 0)
|
||||||
nRows = Math.ceil(children.length / nColumns);
|
nRows = Math.ceil(children.length / nColumns);
|
||||||
|
@ -20,6 +20,25 @@ const KEYBOARD_TYPE = 'keyboard-type';
|
|||||||
const A11Y_APPLICATIONS_SCHEMA = 'org.gnome.desktop.a11y.applications';
|
const A11Y_APPLICATIONS_SCHEMA = 'org.gnome.desktop.a11y.applications';
|
||||||
const SHOW_KEYBOARD = 'screen-keyboard-enabled';
|
const SHOW_KEYBOARD = 'screen-keyboard-enabled';
|
||||||
|
|
||||||
|
// Key constants taken from Antler
|
||||||
|
// FIXME: ought to be moved into libcaribou
|
||||||
|
const PRETTY_KEYS = {
|
||||||
|
'BackSpace': '\u232b',
|
||||||
|
'space': ' ',
|
||||||
|
'Return': '\u23ce',
|
||||||
|
'Caribou_Prefs': '\u2328',
|
||||||
|
'Caribou_ShiftUp': '\u2b06',
|
||||||
|
'Caribou_ShiftDown': '\u2b07',
|
||||||
|
'Caribou_Emoticons': '\u263a',
|
||||||
|
'Caribou_Symbols': '123',
|
||||||
|
'Caribou_Symbols_More': '{#*',
|
||||||
|
'Caribou_Alpha': 'Abc',
|
||||||
|
'Tab': 'Tab',
|
||||||
|
'Escape': 'Esc',
|
||||||
|
'Control_L': 'Ctrl',
|
||||||
|
'Alt_L': 'Alt'
|
||||||
|
};
|
||||||
|
|
||||||
const CaribouKeyboardIface = <interface name='org.gnome.Caribou.Keyboard'>
|
const CaribouKeyboardIface = <interface name='org.gnome.Caribou.Keyboard'>
|
||||||
<method name='Show'>
|
<method name='Show'>
|
||||||
<arg type='u' direction='in' />
|
<arg type='u' direction='in' />
|
||||||
@ -79,7 +98,17 @@ const Key = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_makeKey: function () {
|
_makeKey: function () {
|
||||||
let label = GLib.markup_escape_text(this._key.label, -1);
|
let label = this._key.name;
|
||||||
|
|
||||||
|
if (label.length > 1) {
|
||||||
|
let pretty = PRETTY_KEYS[label];
|
||||||
|
if (pretty)
|
||||||
|
label = pretty;
|
||||||
|
else
|
||||||
|
label = this._getUnichar(this._key);
|
||||||
|
}
|
||||||
|
|
||||||
|
label = GLib.markup_escape_text(label, -1);
|
||||||
let button = new St.Button ({ label: label,
|
let button = new St.Button ({ label: label,
|
||||||
style_class: 'keyboard-key' });
|
style_class: 'keyboard-key' });
|
||||||
|
|
||||||
|
@ -128,6 +128,8 @@ const LayoutManager = new Lang.Class({
|
|||||||
this.trayBox = new St.Widget({ name: 'trayBox',
|
this.trayBox = new St.Widget({ name: 'trayBox',
|
||||||
layout_manager: new Clutter.BinLayout() });
|
layout_manager: new Clutter.BinLayout() });
|
||||||
this.addChrome(this.trayBox);
|
this.addChrome(this.trayBox);
|
||||||
|
this.trayBox.connect('allocation-changed',
|
||||||
|
Lang.bind(this, this._updateTrayBarrier));
|
||||||
|
|
||||||
this.keyboardBox = new St.BoxLayout({ name: 'keyboardBox',
|
this.keyboardBox = new St.BoxLayout({ name: 'keyboardBox',
|
||||||
reactive: true,
|
reactive: true,
|
||||||
@ -278,6 +280,22 @@ const LayoutManager = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_updateTrayBarrier: function() {
|
||||||
|
let monitor = this.bottomMonitor;
|
||||||
|
|
||||||
|
if (this._trayBarrier)
|
||||||
|
global.destroy_pointer_barrier(this._trayBarrier);
|
||||||
|
|
||||||
|
if (Main.messageTray) {
|
||||||
|
this._trayBarrier =
|
||||||
|
global.create_pointer_barrier(monitor.x + monitor.width, monitor.y + monitor.height - Main.messageTray.actor.height,
|
||||||
|
monitor.x + monitor.width, monitor.y + monitor.height,
|
||||||
|
4 /* BarrierNegativeX */);
|
||||||
|
} else {
|
||||||
|
this._trayBarrier = 0;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
_monitorsChanged: function() {
|
_monitorsChanged: function() {
|
||||||
this._updateMonitors();
|
this._updateMonitors();
|
||||||
this._updateBoxes();
|
this._updateBoxes();
|
||||||
|
@ -69,7 +69,7 @@ let _overridesSettings = null;
|
|||||||
let background = null;
|
let background = null;
|
||||||
|
|
||||||
function _sessionUpdated() {
|
function _sessionUpdated() {
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-panel-run-dialog', sessionMode.hasRunDialog ? Util.wrapKeybinding(openRunDialog, true) : null);
|
Meta.keybindings_set_custom_handler('panel-run-dialog', sessionMode.hasRunDialog ? openRunDialog : null);
|
||||||
if (sessionMode.isGreeter)
|
if (sessionMode.isGreeter)
|
||||||
screenShield.showDialog();
|
screenShield.showDialog();
|
||||||
}
|
}
|
||||||
@ -155,14 +155,8 @@ function start() {
|
|||||||
|
|
||||||
global.screen.override_workspace_layout(Meta.ScreenCorner.TOPLEFT,
|
global.screen.override_workspace_layout(Meta.ScreenCorner.TOPLEFT,
|
||||||
false, -1, 1);
|
false, -1, 1);
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-panel-main-menu', Util.wrapKeybinding(Lang.bind(overview, function() {
|
Meta.keybindings_set_custom_handler('panel-main-menu', Lang.bind(overview, overview.toggle));
|
||||||
this.toggle();
|
global.display.connect('overlay-key', Lang.bind(overview, overview.toggle));
|
||||||
return true;
|
|
||||||
}), true));
|
|
||||||
global.display.connect('overlay-key', Util.wrapKeybinding(Lang.bind(overview, function() {
|
|
||||||
this.toggle();
|
|
||||||
return true;
|
|
||||||
}), true));
|
|
||||||
|
|
||||||
sessionMode.connect('update', _sessionUpdated);
|
sessionMode.connect('update', _sessionUpdated);
|
||||||
_sessionUpdated();
|
_sessionUpdated();
|
||||||
@ -173,6 +167,8 @@ function start() {
|
|||||||
|
|
||||||
_startDate = new Date();
|
_startDate = new Date();
|
||||||
|
|
||||||
|
global.stage.connect('captured-event', _globalKeyPressHandler);
|
||||||
|
|
||||||
log('GNOME Shell started at ' + _startDate);
|
log('GNOME Shell started at ' + _startDate);
|
||||||
|
|
||||||
let perfModuleName = GLib.getenv("SHELL_PERF_MODULE");
|
let perfModuleName = GLib.getenv("SHELL_PERF_MODULE");
|
||||||
@ -469,6 +465,80 @@ function getWindowActorsForWorkspace(workspaceIndex) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// This function encapsulates hacks to make certain global keybindings
|
||||||
|
// work even when we are in one of our modes where global keybindings
|
||||||
|
// are disabled with a global grab. (When there is a global grab, then
|
||||||
|
// all key events will be delivered to the stage, so ::captured-event
|
||||||
|
// on the stage can be used for global keybindings.)
|
||||||
|
function _globalKeyPressHandler(actor, event) {
|
||||||
|
if (modalCount == 0)
|
||||||
|
return false;
|
||||||
|
if (event.type() != Clutter.EventType.KEY_PRESS)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
if (!sessionMode.allowKeybindingsWhenModal) {
|
||||||
|
if (modalCount > (overview.visible ? 1 : 0))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
let symbol = event.get_key_symbol();
|
||||||
|
let keyCode = event.get_key_code();
|
||||||
|
let ignoredModifiers = global.display.get_ignored_modifier_mask();
|
||||||
|
let modifierState = event.get_state() & ~ignoredModifiers;
|
||||||
|
|
||||||
|
// This relies on the fact that Clutter.ModifierType is the same as Gdk.ModifierType
|
||||||
|
let action = global.display.get_keybinding_action(keyCode, modifierState);
|
||||||
|
|
||||||
|
if (action == Meta.KeyBindingAction.SWITCH_PANELS) {
|
||||||
|
ctrlAltTabManager.popup(modifierState & Clutter.ModifierType.SHIFT_MASK,
|
||||||
|
modifierState);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch (action) {
|
||||||
|
// left/right would effectively act as synonyms for up/down if we enabled them;
|
||||||
|
// but that could be considered confusing; we also disable them in the main view.
|
||||||
|
//
|
||||||
|
// case Meta.KeyBindingAction.WORKSPACE_LEFT:
|
||||||
|
// if (!sessionMode.hasWorkspaces)
|
||||||
|
// return false;
|
||||||
|
//
|
||||||
|
// wm.actionMoveWorkspaceLeft();
|
||||||
|
// return true;
|
||||||
|
// case Meta.KeyBindingAction.WORKSPACE_RIGHT:
|
||||||
|
// if (!sessionMode.hasWorkspaces)
|
||||||
|
// return false;
|
||||||
|
//
|
||||||
|
// wm.actionMoveWorkspaceRight();
|
||||||
|
// return true;
|
||||||
|
case Meta.KeyBindingAction.WORKSPACE_UP:
|
||||||
|
if (!sessionMode.hasWorkspaces)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
wm.actionMoveWorkspace(Meta.MotionDirection.UP);
|
||||||
|
return true;
|
||||||
|
case Meta.KeyBindingAction.WORKSPACE_DOWN:
|
||||||
|
if (!sessionMode.hasWorkspaces)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
wm.actionMoveWorkspace(Meta.MotionDirection.DOWN);
|
||||||
|
return true;
|
||||||
|
case Meta.KeyBindingAction.PANEL_RUN_DIALOG:
|
||||||
|
case Meta.KeyBindingAction.COMMAND_2:
|
||||||
|
if (!sessionMode.hasRunDialog)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
openRunDialog();
|
||||||
|
return true;
|
||||||
|
case Meta.KeyBindingAction.PANEL_MAIN_MENU:
|
||||||
|
case Meta.KeyBindingAction.OVERLAY_KEY:
|
||||||
|
overview.hide();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
function _findModal(actor) {
|
function _findModal(actor) {
|
||||||
for (let i = 0; i < modalActorFocusStack.length; i++) {
|
for (let i = 0; i < modalActorFocusStack.length; i++) {
|
||||||
if (modalActorFocusStack[i].actor == actor)
|
if (modalActorFocusStack[i].actor == actor)
|
||||||
@ -609,8 +679,6 @@ function openRunDialog() {
|
|||||||
runDialog = new RunDialog.RunDialog();
|
runDialog = new RunDialog.RunDialog();
|
||||||
}
|
}
|
||||||
runDialog.open();
|
runDialog.open();
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -314,7 +314,6 @@ const Notification = new Lang.Class({
|
|||||||
this.resident = false;
|
this.resident = false;
|
||||||
// 'transient' is a reserved keyword in JS, so we have to use an alternate variable name
|
// 'transient' is a reserved keyword in JS, so we have to use an alternate variable name
|
||||||
this.isTransient = false;
|
this.isTransient = false;
|
||||||
this.forFeedback = false;
|
|
||||||
this.expanded = false;
|
this.expanded = false;
|
||||||
this.focused = false;
|
this.focused = false;
|
||||||
this.acknowledged = false;
|
this.acknowledged = false;
|
||||||
@ -714,10 +713,6 @@ const Notification = new Lang.Class({
|
|||||||
this.isTransient = isTransient;
|
this.isTransient = isTransient;
|
||||||
},
|
},
|
||||||
|
|
||||||
setForFeedback: function(forFeedback) {
|
|
||||||
this.forFeedback = forFeedback;
|
|
||||||
},
|
|
||||||
|
|
||||||
setUseActionIcons: function(useIcons) {
|
setUseActionIcons: function(useIcons) {
|
||||||
this._useActionIcons = useIcons;
|
this._useActionIcons = useIcons;
|
||||||
},
|
},
|
||||||
@ -1394,8 +1389,6 @@ const MessageTray = new Lang.Class({
|
|||||||
y_expand: true,
|
y_expand: true,
|
||||||
x_expand: true,
|
x_expand: true,
|
||||||
layout_manager: new Clutter.BinLayout() });
|
layout_manager: new Clutter.BinLayout() });
|
||||||
this._notificationWidget.connect('key-release-event', Lang.bind(this, this._onNotificationKeyRelease));
|
|
||||||
|
|
||||||
this.actor.add_actor(this._notificationWidget);
|
this.actor.add_actor(this._notificationWidget);
|
||||||
|
|
||||||
this._notificationBin = new St.Bin({ y_expand: true });
|
this._notificationBin = new St.Bin({ y_expand: true });
|
||||||
@ -1445,7 +1438,7 @@ const MessageTray = new Lang.Class({
|
|||||||
|
|
||||||
this._closeButton = makeCloseButton();
|
this._closeButton = makeCloseButton();
|
||||||
this._closeButton.hide();
|
this._closeButton.hide();
|
||||||
this._closeButton.connect('clicked', Lang.bind(this, this._closeNotification));
|
this._closeButton.connect('clicked', Lang.bind(this, this._onCloseClicked));
|
||||||
this._notificationWidget.add_actor(this._closeButton);
|
this._notificationWidget.add_actor(this._closeButton);
|
||||||
|
|
||||||
this._idleMonitorBecameActiveId = 0;
|
this._idleMonitorBecameActiveId = 0;
|
||||||
@ -1505,7 +1498,7 @@ const MessageTray = new Lang.Class({
|
|||||||
this._overviewVisible = true;
|
this._overviewVisible = true;
|
||||||
this._grabHelper.ungrab(); // drop modal grab if necessary
|
this._grabHelper.ungrab(); // drop modal grab if necessary
|
||||||
this.actor.add_style_pseudo_class('overview');
|
this.actor.add_style_pseudo_class('overview');
|
||||||
this._updateState();
|
this.show();
|
||||||
}));
|
}));
|
||||||
Main.overview.connect('hiding', Lang.bind(this,
|
Main.overview.connect('hiding', Lang.bind(this,
|
||||||
function() {
|
function() {
|
||||||
@ -1521,10 +1514,6 @@ const MessageTray = new Lang.Class({
|
|||||||
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
||||||
Meta.KeyBindingFlags.NONE,
|
Meta.KeyBindingFlags.NONE,
|
||||||
Lang.bind(this, this.toggleAndNavigate));
|
Lang.bind(this, this.toggleAndNavigate));
|
||||||
global.display.add_keybinding('focus-active-notification',
|
|
||||||
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
|
||||||
Meta.KeyBindingFlags.NONE,
|
|
||||||
Lang.bind(this, this._expandActiveNotification));
|
|
||||||
|
|
||||||
this._summaryItems = [];
|
this._summaryItems = [];
|
||||||
this._chatSummaryItemsCount = 0;
|
this._chatSummaryItemsCount = 0;
|
||||||
@ -1600,19 +1589,7 @@ const MessageTray = new Lang.Class({
|
|||||||
return false;
|
return false;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onNotificationKeyRelease: function(actor, event) {
|
_onCloseClicked: function() {
|
||||||
let ignoredModifiers = global.display.get_ignored_modifier_mask();
|
|
||||||
let modifierState = event.get_state() & ~ignoredModifiers;
|
|
||||||
|
|
||||||
if (event.get_key_symbol() == Clutter.KEY_Escape && modifierState == 0) {
|
|
||||||
this._closeNotification();
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
},
|
|
||||||
|
|
||||||
_closeNotification: function() {
|
|
||||||
if (this._notificationState == State.SHOWN) {
|
if (this._notificationState == State.SHOWN) {
|
||||||
this._closeButton.hide();
|
this._closeButton.hide();
|
||||||
this._notificationClosed = true;
|
this._notificationClosed = true;
|
||||||
@ -1759,6 +1736,11 @@ const MessageTray = new Lang.Class({
|
|||||||
this._updateState();
|
this._updateState();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
show: function() {
|
||||||
|
this._traySummoned = true;
|
||||||
|
this._updateState();
|
||||||
|
},
|
||||||
|
|
||||||
_onNotify: function(source, notification) {
|
_onNotify: function(source, notification) {
|
||||||
if (this._summaryBoxPointerItem && this._summaryBoxPointerItem.source == source) {
|
if (this._summaryBoxPointerItem && this._summaryBoxPointerItem.source == source) {
|
||||||
if (this._summaryBoxPointerState == State.HIDING) {
|
if (this._summaryBoxPointerState == State.HIDING) {
|
||||||
@ -1972,9 +1954,8 @@ const MessageTray = new Lang.Class({
|
|||||||
// Notifications
|
// Notifications
|
||||||
let notificationQueue = this._notificationQueue;
|
let notificationQueue = this._notificationQueue;
|
||||||
let notificationUrgent = notificationQueue.length > 0 && notificationQueue[0].urgency == Urgency.CRITICAL;
|
let notificationUrgent = notificationQueue.length > 0 && notificationQueue[0].urgency == Urgency.CRITICAL;
|
||||||
let notificationForFeedback = notificationQueue.length > 0 && notificationQueue[0].forFeedback;
|
|
||||||
let notificationsLimited = this._busy || this._inFullscreen;
|
let notificationsLimited = this._busy || this._inFullscreen;
|
||||||
let notificationsPending = notificationQueue.length > 0 && (!notificationsLimited || notificationUrgent || notificationForFeedback) && Main.sessionMode.hasNotifications;
|
let notificationsPending = notificationQueue.length > 0 && (!notificationsLimited || notificationUrgent) && Main.sessionMode.hasNotifications;
|
||||||
let nextNotification = notificationQueue.length > 0 ? notificationQueue[0] : null;
|
let nextNotification = notificationQueue.length > 0 ? notificationQueue[0] : null;
|
||||||
let notificationPinned = this._pointerInTray && !this._pointerInSummary && !this._notificationRemoved;
|
let notificationPinned = this._pointerInTray && !this._pointerInSummary && !this._notificationRemoved;
|
||||||
let notificationExpanded = this._notification && this._notification.expanded;
|
let notificationExpanded = this._notification && this._notification.expanded;
|
||||||
@ -2002,7 +1983,7 @@ const MessageTray = new Lang.Class({
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Summary
|
// Summary
|
||||||
let summarySummoned = this._pointerInSummary || this._overviewVisible || this._traySummoned;
|
let summarySummoned = this._pointerInSummary || this._traySummoned;
|
||||||
let summaryPinned = this._pointerInTray || summarySummoned || this._locked;
|
let summaryPinned = this._pointerInTray || summarySummoned || this._locked;
|
||||||
let summaryHovered = this._pointerInTray || this._pointerInSummary;
|
let summaryHovered = this._pointerInTray || this._pointerInSummary;
|
||||||
|
|
||||||
@ -2010,7 +1991,7 @@ const MessageTray = new Lang.Class({
|
|||||||
this._notificationState == State.SHOWN);
|
this._notificationState == State.SHOWN);
|
||||||
let notificationsDone = !notificationsVisible && !notificationsPending;
|
let notificationsDone = !notificationsVisible && !notificationsPending;
|
||||||
|
|
||||||
let summaryOptionalInOverview = this._overviewVisible && !this._locked && !summaryHovered;
|
let summaryOptionalInOverview = !this._locked && !summaryHovered;
|
||||||
let mustHideSummary = (notificationsPending && (notificationUrgent || summaryOptionalInOverview))
|
let mustHideSummary = (notificationsPending && (notificationUrgent || summaryOptionalInOverview))
|
||||||
|| notificationsVisible || !Main.sessionMode.hasNotifications;
|
|| notificationsVisible || !Main.sessionMode.hasNotifications;
|
||||||
|
|
||||||
@ -2356,13 +2337,6 @@ const MessageTray = new Lang.Class({
|
|||||||
notification.destroy(NotificationDestroyedReason.EXPIRED);
|
notification.destroy(NotificationDestroyedReason.EXPIRED);
|
||||||
},
|
},
|
||||||
|
|
||||||
_expandActiveNotification: function() {
|
|
||||||
if (!this._notification)
|
|
||||||
return;
|
|
||||||
|
|
||||||
this._expandNotification(false);
|
|
||||||
},
|
|
||||||
|
|
||||||
_expandNotification: function(autoExpanding) {
|
_expandNotification: function(autoExpanding) {
|
||||||
// Don't grab focus in notifications that are auto-expanded.
|
// Don't grab focus in notifications that are auto-expanded.
|
||||||
if (!autoExpanding)
|
if (!autoExpanding)
|
||||||
|
@ -10,6 +10,7 @@ const St = imports.gi.St;
|
|||||||
const Shell = imports.gi.Shell;
|
const Shell = imports.gi.Shell;
|
||||||
const Gdk = imports.gi.Gdk;
|
const Gdk = imports.gi.Gdk;
|
||||||
|
|
||||||
|
const CenterLayout = imports.ui.centerLayout;
|
||||||
const Dash = imports.ui.dash;
|
const Dash = imports.ui.dash;
|
||||||
const DND = imports.ui.dnd;
|
const DND = imports.ui.dnd;
|
||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
@ -23,29 +24,8 @@ const WorkspaceThumbnail = imports.ui.workspaceThumbnail;
|
|||||||
// Time for initial animation going into Overview mode
|
// Time for initial animation going into Overview mode
|
||||||
const ANIMATION_TIME = 0.25;
|
const ANIMATION_TIME = 0.25;
|
||||||
|
|
||||||
// XXX -- grab this automatically. Hard to do.
|
|
||||||
const DASH_MAX_WIDTH = 96;
|
|
||||||
|
|
||||||
const DND_WINDOW_SWITCH_TIMEOUT = 1250;
|
const DND_WINDOW_SWITCH_TIMEOUT = 1250;
|
||||||
|
|
||||||
const GLSL_DIM_EFFECT_DECLARATIONS = '';
|
|
||||||
const GLSL_DIM_EFFECT_CODE = '\
|
|
||||||
vec2 dist = cogl_tex_coord_in[0].xy - vec2(0.5, 0.5); \
|
|
||||||
float elipse_radius = 0.5; \
|
|
||||||
/* from https://bugzilla.gnome.org/show_bug.cgi?id=669798: \
|
|
||||||
the alpha on the gradient goes from 165 at its darkest to 98 at its most transparent. */ \
|
|
||||||
float y = 165.0 / 255.0; \
|
|
||||||
float x = 98.0 / 255.0; \
|
|
||||||
/* interpolate darkening value, based on distance from screen center */ \
|
|
||||||
float val = min(length(dist), elipse_radius); \
|
|
||||||
float a = mix(x, y, val / elipse_radius); \
|
|
||||||
/* dim_factor varies from [1.0 -> 0.5] when overview is showing \
|
|
||||||
We use it to smooth value, then we clamp it to valid color interval */ \
|
|
||||||
a = clamp(a - cogl_color_in.r + 0.5, 0.0, 1.0); \
|
|
||||||
/* We\'re blending between: color and black color (obviously omitted in the equation) */ \
|
|
||||||
cogl_color_out.xyz = cogl_color_out.xyz * (1.0 - a); \
|
|
||||||
cogl_color_out.a = 1.0;';
|
|
||||||
|
|
||||||
const SwipeScrollDirection = {
|
const SwipeScrollDirection = {
|
||||||
NONE: 0,
|
NONE: 0,
|
||||||
HORIZONTAL: 1,
|
HORIZONTAL: 1,
|
||||||
@ -75,14 +55,7 @@ const ShellInfo = new Lang.Class({
|
|||||||
this._source.destroy();
|
this._source.destroy();
|
||||||
},
|
},
|
||||||
|
|
||||||
setMessage: function(text, options) {
|
setMessage: function(text, undoCallback, undoLabel) {
|
||||||
options = Params.parse(options, { undoCallback: null,
|
|
||||||
forFeedback: false
|
|
||||||
});
|
|
||||||
|
|
||||||
let undoCallback = options.undoCallback;
|
|
||||||
let forFeedback = options.forFeedback;
|
|
||||||
|
|
||||||
if (this._source == null) {
|
if (this._source == null) {
|
||||||
this._source = new MessageTray.SystemNotificationSource();
|
this._source = new MessageTray.SystemNotificationSource();
|
||||||
this._source.connect('destroy', Lang.bind(this,
|
this._source.connect('destroy', Lang.bind(this,
|
||||||
@ -96,7 +69,6 @@ const ShellInfo = new Lang.Class({
|
|||||||
if (this._source.notifications.length == 0) {
|
if (this._source.notifications.length == 0) {
|
||||||
notification = new MessageTray.Notification(this._source, text, null);
|
notification = new MessageTray.Notification(this._source, text, null);
|
||||||
notification.setTransient(true);
|
notification.setTransient(true);
|
||||||
notification.setForFeedback(forFeedback);
|
|
||||||
} else {
|
} else {
|
||||||
notification = this._source.notifications[0];
|
notification = this._source.notifications[0];
|
||||||
notification.update(text, null, { clear: true });
|
notification.update(text, null, { clear: true });
|
||||||
@ -104,8 +76,10 @@ const ShellInfo = new Lang.Class({
|
|||||||
|
|
||||||
this._undoCallback = undoCallback;
|
this._undoCallback = undoCallback;
|
||||||
if (undoCallback) {
|
if (undoCallback) {
|
||||||
notification.addButton('system-undo', _("Undo"));
|
notification.addButton('system-undo',
|
||||||
notification.connect('action-invoked', Lang.bind(this, this._onUndoClicked));
|
undoLabel ? undoLabel : _("Undo"));
|
||||||
|
notification.connect('action-invoked',
|
||||||
|
Lang.bind(this, this._onUndoClicked));
|
||||||
}
|
}
|
||||||
|
|
||||||
this._source.notify(notification);
|
this._source.notify(notification);
|
||||||
@ -137,33 +111,24 @@ const Overview = new Lang.Class({
|
|||||||
// scenes which allows us to show the background with different
|
// scenes which allows us to show the background with different
|
||||||
// rendering options without duplicating the texture data.
|
// rendering options without duplicating the texture data.
|
||||||
this._background = Meta.BackgroundActor.new_for_screen(global.screen);
|
this._background = Meta.BackgroundActor.new_for_screen(global.screen);
|
||||||
this._background.add_glsl_snippet(Meta.SnippetHook.FRAGMENT,
|
|
||||||
GLSL_DIM_EFFECT_DECLARATIONS,
|
|
||||||
GLSL_DIM_EFFECT_CODE,
|
|
||||||
false);
|
|
||||||
this._background.hide();
|
this._background.hide();
|
||||||
global.overlay_group.add_actor(this._background);
|
global.overlay_group.add_actor(this._background);
|
||||||
|
|
||||||
this._desktopFade = new St.Bin();
|
this._desktopFade = new St.Bin();
|
||||||
global.overlay_group.add_actor(this._desktopFade);
|
global.overlay_group.add_actor(this._desktopFade);
|
||||||
|
|
||||||
this._spacing = 0;
|
|
||||||
|
|
||||||
/* Translators: This is the main view to select
|
/* Translators: This is the main view to select
|
||||||
activities. See also note for "Activities" string. */
|
activities. See also note for "Activities" string. */
|
||||||
this._group = new St.Widget({ name: 'overview',
|
this._overview = new St.BoxLayout({ name: 'overview',
|
||||||
accessible_name: _("Overview"),
|
accessible_name: _("Overview"),
|
||||||
reactive: true });
|
reactive: true,
|
||||||
this._group._delegate = this;
|
vertical: true });
|
||||||
this._group.connect('style-changed',
|
this._overview._delegate = this;
|
||||||
Lang.bind(this, function() {
|
|
||||||
let node = this._group.get_theme_node();
|
let layout = new CenterLayout.CenterLayout();
|
||||||
let spacing = node.get_length('spacing');
|
CenterLayout.connectSpacing(layout);
|
||||||
if (spacing != this._spacing) {
|
this._group = new St.Widget({ name: 'overview-group',
|
||||||
this._spacing = spacing;
|
layout_manager: layout });
|
||||||
this._relayout();
|
|
||||||
}
|
|
||||||
}));
|
|
||||||
|
|
||||||
this._scrollDirection = SwipeScrollDirection.NONE;
|
this._scrollDirection = SwipeScrollDirection.NONE;
|
||||||
this._scrollAdjustment = null;
|
this._scrollAdjustment = null;
|
||||||
@ -176,18 +141,19 @@ const Overview = new Lang.Class({
|
|||||||
this._modal = false; // have a modal grab
|
this._modal = false; // have a modal grab
|
||||||
this.animationInProgress = false;
|
this.animationInProgress = false;
|
||||||
this._hideInProgress = false;
|
this._hideInProgress = false;
|
||||||
|
this.searchActive = false;
|
||||||
|
this.appsActive = false;
|
||||||
|
|
||||||
// During transitions, we raise this to the top to avoid having the overview
|
// During transitions, we raise this to the top to avoid having the overview
|
||||||
// area be reactive; it causes too many issues such as double clicks on
|
// area be reactive; it causes too many issues such as double clicks on
|
||||||
// Dash elements, or mouseover handlers in the workspaces.
|
// Dash elements, or mouseover handlers in the workspaces.
|
||||||
this._coverPane = new Clutter.Rectangle({ opacity: 0,
|
this._coverPane = new Clutter.Rectangle({ opacity: 0,
|
||||||
reactive: true });
|
reactive: true });
|
||||||
this._group.add_actor(this._coverPane);
|
this._overview.add_actor(this._coverPane);
|
||||||
this._coverPane.connect('event', Lang.bind(this, function (actor, event) { return true; }));
|
this._coverPane.connect('event', Lang.bind(this, function (actor, event) { return true; }));
|
||||||
|
|
||||||
|
this._overview.hide();
|
||||||
this._group.hide();
|
global.overlay_group.add_actor(this._overview);
|
||||||
global.overlay_group.add_actor(this._group);
|
|
||||||
|
|
||||||
this._coverPane.hide();
|
this._coverPane.hide();
|
||||||
|
|
||||||
@ -199,6 +165,8 @@ const Overview = new Lang.Class({
|
|||||||
Main.xdndHandler.connect('drag-begin', Lang.bind(this, this._onDragBegin));
|
Main.xdndHandler.connect('drag-begin', Lang.bind(this, this._onDragBegin));
|
||||||
Main.xdndHandler.connect('drag-end', Lang.bind(this, this._onDragEnd));
|
Main.xdndHandler.connect('drag-end', Lang.bind(this, this._onDragEnd));
|
||||||
|
|
||||||
|
global.screen.connect('restacked', Lang.bind(this, this._onRestacked));
|
||||||
|
|
||||||
this._windowSwitchTimeoutId = 0;
|
this._windowSwitchTimeoutId = 0;
|
||||||
this._windowSwitchTimestamp = 0;
|
this._windowSwitchTimestamp = 0;
|
||||||
this._lastActiveWorkspaceIndex = -1;
|
this._lastActiveWorkspaceIndex = -1;
|
||||||
@ -221,6 +189,13 @@ const Overview = new Lang.Class({
|
|||||||
|
|
||||||
this._shellInfo = new ShellInfo();
|
this._shellInfo = new ShellInfo();
|
||||||
|
|
||||||
|
// Add a clone of the panel to the overview so spacing and such is
|
||||||
|
// automatic
|
||||||
|
this._panelGhost = new St.Bin({ child: new Clutter.Clone({ source: Main.panel.actor }),
|
||||||
|
reactive: false,
|
||||||
|
opacity: 0 });
|
||||||
|
this._overview.add_actor(this._panelGhost);
|
||||||
|
|
||||||
this._searchEntry = new St.Entry({ name: 'searchEntry',
|
this._searchEntry = new St.Entry({ name: 'searchEntry',
|
||||||
/* Translators: this is the text displayed
|
/* Translators: this is the text displayed
|
||||||
in the search entry when no search is
|
in the search entry when no search is
|
||||||
@ -229,16 +204,13 @@ const Overview = new Lang.Class({
|
|||||||
hint_text: _("Type to search..."),
|
hint_text: _("Type to search..."),
|
||||||
track_hover: true,
|
track_hover: true,
|
||||||
can_focus: true });
|
can_focus: true });
|
||||||
this._group.add_actor(this._searchEntry);
|
this._searchEntryBin = new St.Bin({ child: this._searchEntry,
|
||||||
|
x_align: St.Align.MIDDLE });
|
||||||
this._dash = new Dash.Dash();
|
this._overview.add_actor(this._searchEntryBin);
|
||||||
this._viewSelector = new ViewSelector.ViewSelector(this._searchEntry,
|
|
||||||
this._dash.showAppsButton);
|
|
||||||
this._group.add_actor(this._viewSelector.actor);
|
|
||||||
this._group.add_actor(this._dash.actor);
|
|
||||||
|
|
||||||
// TODO - recalculate everything when desktop size changes
|
// TODO - recalculate everything when desktop size changes
|
||||||
this._dash.actor.add_constraint(this._viewSelector.constrainHeight);
|
this._dash = new Dash.Dash();
|
||||||
|
this._group.add_actor(this._dash.actor);
|
||||||
this.dashIconSize = this._dash.iconSize;
|
this.dashIconSize = this._dash.iconSize;
|
||||||
this._dash.connect('icon-size-changed',
|
this._dash.connect('icon-size-changed',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
@ -249,6 +221,82 @@ const Overview = new Lang.Class({
|
|||||||
// the left of the overview
|
// the left of the overview
|
||||||
Main.ctrlAltTabManager.addGroup(this._dash.actor, _("Dash"), 'user-bookmarks-symbolic');
|
Main.ctrlAltTabManager.addGroup(this._dash.actor, _("Dash"), 'user-bookmarks-symbolic');
|
||||||
|
|
||||||
|
this._viewSelector = new ViewSelector.ViewSelector(this._searchEntry,
|
||||||
|
this._dash.showAppsButton);
|
||||||
|
this._group.add_actor(this._viewSelector.actor);
|
||||||
|
|
||||||
|
this._thumbnailsBox = new WorkspaceThumbnail.ThumbnailsBox();
|
||||||
|
this._group.add_actor(this._thumbnailsBox.actor);
|
||||||
|
|
||||||
|
// TODO: unique icon
|
||||||
|
Main.ctrlAltTabManager.addGroup(this._thumbnailsBox.actor, _("Workspaces"), 'user-bookmarks-symbolic');
|
||||||
|
|
||||||
|
// Add our same-line elements after the search entry
|
||||||
|
this._overview.add_actor(this._group);
|
||||||
|
|
||||||
|
// Then account for message tray
|
||||||
|
this._messageTrayGhost = new St.Bin({ child: new Clutter.Clone({ source: Main.messageTray.actor }),
|
||||||
|
reactive: false,
|
||||||
|
opacity: 0 });
|
||||||
|
this._overview.add_actor(this._messageTrayGhost);
|
||||||
|
|
||||||
|
this._viewSelector.connect('search-begin', Lang.bind(this,
|
||||||
|
function() {
|
||||||
|
this.searchActive = true;
|
||||||
|
this._dash.hide();
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
Main.messageTray.hide();
|
||||||
|
}));
|
||||||
|
this._viewSelector.connect('search-cancelled', Lang.bind(this,
|
||||||
|
function() {
|
||||||
|
this.searchActive = false;
|
||||||
|
this._dash.show();
|
||||||
|
this._thumbnailsBox.show();
|
||||||
|
// search-cancelled is emitted if we leave the overview
|
||||||
|
// directly from searching. That means the message tray will
|
||||||
|
// be shown when we reach the workspace. Don't do this, only
|
||||||
|
// show the message tray on search-cancelled if we are still
|
||||||
|
// in the overview/not transitioning out of it.
|
||||||
|
if (this.visible && !this.animationInProgress)
|
||||||
|
Main.messageTray.show();
|
||||||
|
}));
|
||||||
|
this._viewSelector.connect('apps-button-checked', Lang.bind(this,
|
||||||
|
function(vs, checked) {
|
||||||
|
this.appsActive = checked;
|
||||||
|
if (checked) {
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
Main.messageTray.hide();
|
||||||
|
} else {
|
||||||
|
this._thumbnailsBox.show();
|
||||||
|
if (this.visible && !this.animationInProgress)
|
||||||
|
Main.messageTray.show();
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
|
||||||
|
this.connect('app-drag-begin',
|
||||||
|
Lang.bind(this, function () {
|
||||||
|
this._dash.show();
|
||||||
|
this._thumbnailsBox.show();
|
||||||
|
}));
|
||||||
|
this.connect('app-drag-cancelled',
|
||||||
|
Lang.bind(this, function () {
|
||||||
|
if (this.searchActive) {
|
||||||
|
this._dash.hide();
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
} else if (this.appsActive) {
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
this.connect('app-drag-end',
|
||||||
|
Lang.bind(this, function () {
|
||||||
|
if (this.searchActive) {
|
||||||
|
this._dash.hide();
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
} else if (this.appsActive) {
|
||||||
|
this._thumbnailsBox.hide();
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
|
||||||
Main.layoutManager.connect('monitors-changed', Lang.bind(this, this._relayout));
|
Main.layoutManager.connect('monitors-changed', Lang.bind(this, this._relayout));
|
||||||
this._relayout();
|
this._relayout();
|
||||||
},
|
},
|
||||||
@ -261,16 +309,11 @@ const Overview = new Lang.Class({
|
|||||||
this._viewSelector.removeSearchProvider(provider);
|
this._viewSelector.removeSearchProvider(provider);
|
||||||
},
|
},
|
||||||
|
|
||||||
//
|
setMessage: function(text, undoCallback, undoLabel) {
|
||||||
// options:
|
|
||||||
// - undoCallback (function): the callback to be called if undo support is needed
|
|
||||||
// - forFeedback (boolean): whether the message is for direct feedback of a user action
|
|
||||||
//
|
|
||||||
setMessage: function(text, options) {
|
|
||||||
if (this.isDummy)
|
if (this.isDummy)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this._shellInfo.setMessage(text, options);
|
this._shellInfo.setMessage(text, undoCallback, undoLabel);
|
||||||
},
|
},
|
||||||
|
|
||||||
_onDragBegin: function() {
|
_onDragBegin: function() {
|
||||||
@ -519,55 +562,41 @@ const Overview = new Lang.Class({
|
|||||||
this.hide();
|
this.hide();
|
||||||
|
|
||||||
let primary = Main.layoutManager.primaryMonitor;
|
let primary = Main.layoutManager.primaryMonitor;
|
||||||
let rtl = (Clutter.get_default_text_direction() == Clutter.TextDirection.RTL);
|
|
||||||
|
|
||||||
let contentY = Main.panel.actor.height;
|
let contentY = Main.panel.actor.height;
|
||||||
let contentHeight = primary.height - contentY - Main.messageTray.actor.height;
|
let contentHeight = primary.height - contentY - Main.messageTray.actor.height;
|
||||||
|
|
||||||
this._group.set_position(primary.x, primary.y);
|
this._overview.set_position(primary.x, primary.y);
|
||||||
this._group.set_size(primary.width, primary.height);
|
this._overview.set_size(primary.width, primary.height);
|
||||||
|
|
||||||
this._coverPane.set_position(0, contentY);
|
this._coverPane.set_position(0, contentY);
|
||||||
this._coverPane.set_size(primary.width, contentHeight);
|
this._coverPane.set_size(primary.width, contentHeight);
|
||||||
|
},
|
||||||
|
|
||||||
let searchWidth = this._searchEntry.get_width();
|
_onRestacked: function() {
|
||||||
let searchHeight = this._searchEntry.get_height();
|
let stack = global.get_window_actors();
|
||||||
let searchX = (primary.width - searchWidth) / 2;
|
let stackIndices = {};
|
||||||
let searchY = contentY + this._spacing;
|
|
||||||
|
|
||||||
let dashWidth = DASH_MAX_WIDTH;
|
for (let i = 0; i < stack.length; i++) {
|
||||||
let dashY = searchY + searchHeight + this._spacing;
|
// Use the stable sequence for an integer to use as a hash key
|
||||||
let dashX;
|
stackIndices[stack[i].get_meta_window().get_stable_sequence()] = i;
|
||||||
if (rtl) {
|
|
||||||
this._dash.actor.set_anchor_point_from_gravity(Clutter.Gravity.NORTH_EAST);
|
|
||||||
dashX = primary.width;
|
|
||||||
} else {
|
|
||||||
dashX = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let viewX = rtl ? 0 : dashWidth + this._spacing;
|
this.emit('sync-window-stacking', stackIndices);
|
||||||
let viewY = searchY + searchHeight + this._spacing;
|
|
||||||
let viewWidth = primary.width - dashWidth - this._spacing;
|
|
||||||
let viewHeight = contentHeight - this._spacing - viewY;
|
|
||||||
|
|
||||||
this._searchEntry.set_position(searchX, searchY);
|
|
||||||
this._dash.actor.set_position(dashX, dashY);
|
|
||||||
this._viewSelector.actor.set_position(viewX, viewY);
|
|
||||||
this._viewSelector.actor.set_size(viewWidth, viewHeight);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
//// Public methods ////
|
//// Public methods ////
|
||||||
|
|
||||||
beginItemDrag: function(source) {
|
beginAppDrag: function(source) {
|
||||||
this.emit('item-drag-begin');
|
this.emit('app-drag-begin');
|
||||||
},
|
},
|
||||||
|
|
||||||
cancelledItemDrag: function(source) {
|
cancelledAppDrag: function(source) {
|
||||||
this.emit('item-drag-cancelled');
|
this.emit('app-drag-cancelled');
|
||||||
},
|
},
|
||||||
|
|
||||||
endItemDrag: function(source) {
|
endAppDrag: function(source) {
|
||||||
this.emit('item-drag-end');
|
this.emit('app-drag-end');
|
||||||
},
|
},
|
||||||
|
|
||||||
beginWindowDrag: function(source) {
|
beginWindowDrag: function(source) {
|
||||||
@ -591,13 +620,13 @@ const Overview = new Lang.Class({
|
|||||||
if (this._shown)
|
if (this._shown)
|
||||||
return;
|
return;
|
||||||
// Do this manually instead of using _syncInputMode, to handle failure
|
// Do this manually instead of using _syncInputMode, to handle failure
|
||||||
if (!Main.pushModal(this._group))
|
if (!Main.pushModal(this._overview))
|
||||||
return;
|
return;
|
||||||
this._modal = true;
|
this._modal = true;
|
||||||
this._animateVisible();
|
this._animateVisible();
|
||||||
this._shown = true;
|
this._shown = true;
|
||||||
|
|
||||||
this._buttonPressId = this._group.connect('button-press-event',
|
this._buttonPressId = this._overview.connect('button-press-event',
|
||||||
Lang.bind(this, this._onButtonPress));
|
Lang.bind(this, this._onButtonPress));
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -641,12 +670,12 @@ const Overview = new Lang.Class({
|
|||||||
// Disable unredirection while in the overview
|
// Disable unredirection while in the overview
|
||||||
Meta.disable_unredirect_for_screen(global.screen);
|
Meta.disable_unredirect_for_screen(global.screen);
|
||||||
global.window_group.hide();
|
global.window_group.hide();
|
||||||
this._group.show();
|
this._overview.show();
|
||||||
this._background.show();
|
this._background.show();
|
||||||
this._viewSelector.show();
|
this._viewSelector.show();
|
||||||
|
|
||||||
this._group.opacity = 0;
|
this._overview.opacity = 0;
|
||||||
Tweener.addTween(this._group,
|
Tweener.addTween(this._overview,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME,
|
||||||
@ -655,7 +684,7 @@ const Overview = new Lang.Class({
|
|||||||
});
|
});
|
||||||
|
|
||||||
Tweener.addTween(this._background,
|
Tweener.addTween(this._background,
|
||||||
{ dim_factor: 0.8,
|
{ dim_factor: 0.4,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
@ -700,7 +729,7 @@ const Overview = new Lang.Class({
|
|||||||
this._syncInputMode();
|
this._syncInputMode();
|
||||||
|
|
||||||
if (this._buttonPressId > 0)
|
if (this._buttonPressId > 0)
|
||||||
this._group.disconnect(this._buttonPressId);
|
this._overview.disconnect(this._buttonPressId);
|
||||||
this._buttonPressId = 0;
|
this._buttonPressId = 0;
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -742,20 +771,20 @@ const Overview = new Lang.Class({
|
|||||||
|
|
||||||
if (this._shown) {
|
if (this._shown) {
|
||||||
if (!this._modal) {
|
if (!this._modal) {
|
||||||
if (Main.pushModal(this._group))
|
if (Main.pushModal(this._overview))
|
||||||
this._modal = true;
|
this._modal = true;
|
||||||
else
|
else
|
||||||
this.hide();
|
this.hide();
|
||||||
}
|
}
|
||||||
} else if (this._shownTemporarily) {
|
} else if (this._shownTemporarily) {
|
||||||
if (this._modal) {
|
if (this._modal) {
|
||||||
Main.popModal(this._group);
|
Main.popModal(this._overview);
|
||||||
this._modal = false;
|
this._modal = false;
|
||||||
}
|
}
|
||||||
global.stage_input_mode = Shell.StageInputMode.FULLSCREEN;
|
global.stage_input_mode = Shell.StageInputMode.FULLSCREEN;
|
||||||
} else {
|
} else {
|
||||||
if (this._modal) {
|
if (this._modal) {
|
||||||
Main.popModal(this._group);
|
Main.popModal(this._overview);
|
||||||
this._modal = false;
|
this._modal = false;
|
||||||
}
|
}
|
||||||
else if (global.stage_input_mode == Shell.StageInputMode.FULLSCREEN)
|
else if (global.stage_input_mode == Shell.StageInputMode.FULLSCREEN)
|
||||||
@ -773,7 +802,7 @@ const Overview = new Lang.Class({
|
|||||||
this._viewSelector.zoomFromOverview();
|
this._viewSelector.zoomFromOverview();
|
||||||
|
|
||||||
// Make other elements fade out.
|
// Make other elements fade out.
|
||||||
Tweener.addTween(this._group,
|
Tweener.addTween(this._overview,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME,
|
||||||
@ -815,7 +844,7 @@ const Overview = new Lang.Class({
|
|||||||
this._viewSelector.hide();
|
this._viewSelector.hide();
|
||||||
this._desktopFade.hide();
|
this._desktopFade.hide();
|
||||||
this._background.hide();
|
this._background.hide();
|
||||||
this._group.hide();
|
this._overview.hide();
|
||||||
|
|
||||||
this.visible = false;
|
this.visible = false;
|
||||||
this.animationInProgress = false;
|
this.animationInProgress = false;
|
||||||
|
121
js/ui/panel.js
121
js/ui/panel.js
@ -15,6 +15,7 @@ const Signals = imports.signals;
|
|||||||
const Atk = imports.gi.Atk;
|
const Atk = imports.gi.Atk;
|
||||||
|
|
||||||
|
|
||||||
|
const CenterLayout = imports.ui.centerLayout;
|
||||||
const Config = imports.misc.config;
|
const Config = imports.misc.config;
|
||||||
const CtrlAltTab = imports.ui.ctrlAltTab;
|
const CtrlAltTab = imports.ui.ctrlAltTab;
|
||||||
const DND = imports.ui.dnd;
|
const DND = imports.ui.dnd;
|
||||||
@ -931,12 +932,47 @@ try {
|
|||||||
log('NMApplet is not supported. It is possible that your NetworkManager version is too old');
|
log('NMApplet is not supported. It is possible that your NetworkManager version is too old');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const PanelLayout = new Lang.Class({
|
||||||
|
Name: 'PanelLayout',
|
||||||
|
Extends: CenterLayout.CenterLayout,
|
||||||
|
|
||||||
|
vfunc_allocate: function(container, box, flags) {
|
||||||
|
this.parent(container, box, flags);
|
||||||
|
|
||||||
|
let availWidth = box.x2 - box.x1;
|
||||||
|
let availHeight = box.y2 - box.y1;
|
||||||
|
|
||||||
|
let [left, center, right, leftCorner, rightCorner] = container.get_children();
|
||||||
|
let childBox = new Clutter.ActorBox();
|
||||||
|
|
||||||
|
let cornerMinWidth, cornerMinHeight;
|
||||||
|
let cornerWidth, cornerHeight;
|
||||||
|
|
||||||
|
[cornerMinWidth, cornerWidth] = leftCorner.get_preferred_width(-1);
|
||||||
|
[cornerMinHeight, cornerHeight] = leftCorner.get_preferred_height(-1);
|
||||||
|
childBox.x1 = 0;
|
||||||
|
childBox.x2 = cornerWidth;
|
||||||
|
childBox.y1 = availHeight;
|
||||||
|
childBox.y2 = availHeight + cornerHeight;
|
||||||
|
leftCorner.allocate(childBox, flags);
|
||||||
|
|
||||||
|
[cornerMinWidth, cornerWidth] = rightCorner.get_preferred_width(-1);
|
||||||
|
[cornerMinHeight, cornerHeight] = rightCorner.get_preferred_height(-1);
|
||||||
|
childBox.x1 = availWidth - cornerWidth;
|
||||||
|
childBox.x2 = availWidth;
|
||||||
|
childBox.y1 = availHeight;
|
||||||
|
childBox.y2 = availHeight + cornerHeight;
|
||||||
|
rightCorner.allocate(childBox, flags);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
const Panel = new Lang.Class({
|
const Panel = new Lang.Class({
|
||||||
Name: 'Panel',
|
Name: 'Panel',
|
||||||
|
|
||||||
_init : function() {
|
_init : function() {
|
||||||
this.actor = new Shell.GenericContainer({ name: 'panel',
|
this.actor = new St.Widget({ name: 'panel',
|
||||||
reactive: true });
|
reactive: true,
|
||||||
|
layoutManager: new PanelLayout() });
|
||||||
this.actor._delegate = this;
|
this.actor._delegate = this;
|
||||||
|
|
||||||
this.statusArea = {};
|
this.statusArea = {};
|
||||||
@ -961,7 +997,6 @@ const Panel = new Lang.Class({
|
|||||||
this._leftCorner = new PanelCorner(this._rightBox, St.Side.LEFT);
|
this._leftCorner = new PanelCorner(this._rightBox, St.Side.LEFT);
|
||||||
else
|
else
|
||||||
this._leftCorner = new PanelCorner(this._leftBox, St.Side.LEFT);
|
this._leftCorner = new PanelCorner(this._leftBox, St.Side.LEFT);
|
||||||
|
|
||||||
this.actor.add_actor(this._leftCorner.actor);
|
this.actor.add_actor(this._leftCorner.actor);
|
||||||
|
|
||||||
if (this.actor.get_text_direction() == Clutter.TextDirection.RTL)
|
if (this.actor.get_text_direction() == Clutter.TextDirection.RTL)
|
||||||
@ -970,9 +1005,6 @@ const Panel = new Lang.Class({
|
|||||||
this._rightCorner = new PanelCorner(this._rightBox, St.Side.RIGHT);
|
this._rightCorner = new PanelCorner(this._rightBox, St.Side.RIGHT);
|
||||||
this.actor.add_actor(this._rightCorner.actor);
|
this.actor.add_actor(this._rightCorner.actor);
|
||||||
|
|
||||||
this.actor.connect('get-preferred-width', Lang.bind(this, this._getPreferredWidth));
|
|
||||||
this.actor.connect('get-preferred-height', Lang.bind(this, this._getPreferredHeight));
|
|
||||||
this.actor.connect('allocate', Lang.bind(this, this._allocate));
|
|
||||||
this.actor.connect('button-press-event', Lang.bind(this, this._onButtonPress));
|
this.actor.connect('button-press-event', Lang.bind(this, this._onButtonPress));
|
||||||
|
|
||||||
Main.layoutManager.panelBox.add(this.actor);
|
Main.layoutManager.panelBox.add(this.actor);
|
||||||
@ -983,83 +1015,6 @@ const Panel = new Lang.Class({
|
|||||||
this._updatePanel();
|
this._updatePanel();
|
||||||
},
|
},
|
||||||
|
|
||||||
_getPreferredWidth: function(actor, forHeight, alloc) {
|
|
||||||
alloc.min_size = -1;
|
|
||||||
alloc.natural_size = Main.layoutManager.primaryMonitor.width;
|
|
||||||
},
|
|
||||||
|
|
||||||
_getPreferredHeight: function(actor, forWidth, alloc) {
|
|
||||||
// We don't need to implement this; it's forced by the CSS
|
|
||||||
alloc.min_size = -1;
|
|
||||||
alloc.natural_size = -1;
|
|
||||||
},
|
|
||||||
|
|
||||||
_allocate: function(actor, box, flags) {
|
|
||||||
let allocWidth = box.x2 - box.x1;
|
|
||||||
let allocHeight = box.y2 - box.y1;
|
|
||||||
|
|
||||||
let [leftMinWidth, leftNaturalWidth] = this._leftBox.get_preferred_width(-1);
|
|
||||||
let [centerMinWidth, centerNaturalWidth] = this._centerBox.get_preferred_width(-1);
|
|
||||||
let [rightMinWidth, rightNaturalWidth] = this._rightBox.get_preferred_width(-1);
|
|
||||||
|
|
||||||
let sideWidth, centerWidth;
|
|
||||||
centerWidth = centerNaturalWidth;
|
|
||||||
sideWidth = (allocWidth - centerWidth) / 2;
|
|
||||||
|
|
||||||
let childBox = new Clutter.ActorBox();
|
|
||||||
|
|
||||||
childBox.y1 = 0;
|
|
||||||
childBox.y2 = allocHeight;
|
|
||||||
if (this.actor.get_text_direction() == Clutter.TextDirection.RTL) {
|
|
||||||
childBox.x1 = allocWidth - Math.min(Math.floor(sideWidth),
|
|
||||||
leftNaturalWidth);
|
|
||||||
childBox.x2 = allocWidth;
|
|
||||||
} else {
|
|
||||||
childBox.x1 = 0;
|
|
||||||
childBox.x2 = Math.min(Math.floor(sideWidth),
|
|
||||||
leftNaturalWidth);
|
|
||||||
}
|
|
||||||
this._leftBox.allocate(childBox, flags);
|
|
||||||
|
|
||||||
childBox.x1 = Math.ceil(sideWidth);
|
|
||||||
childBox.y1 = 0;
|
|
||||||
childBox.x2 = childBox.x1 + centerWidth;
|
|
||||||
childBox.y2 = allocHeight;
|
|
||||||
this._centerBox.allocate(childBox, flags);
|
|
||||||
|
|
||||||
childBox.y1 = 0;
|
|
||||||
childBox.y2 = allocHeight;
|
|
||||||
if (this.actor.get_text_direction() == Clutter.TextDirection.RTL) {
|
|
||||||
childBox.x1 = 0;
|
|
||||||
childBox.x2 = Math.min(Math.floor(sideWidth),
|
|
||||||
rightNaturalWidth);
|
|
||||||
} else {
|
|
||||||
childBox.x1 = allocWidth - Math.min(Math.floor(sideWidth),
|
|
||||||
rightNaturalWidth);
|
|
||||||
childBox.x2 = allocWidth;
|
|
||||||
}
|
|
||||||
this._rightBox.allocate(childBox, flags);
|
|
||||||
|
|
||||||
let cornerMinWidth, cornerMinHeight;
|
|
||||||
let cornerWidth, cornerHeight;
|
|
||||||
|
|
||||||
[cornerMinWidth, cornerWidth] = this._leftCorner.actor.get_preferred_width(-1);
|
|
||||||
[cornerMinHeight, cornerHeight] = this._leftCorner.actor.get_preferred_height(-1);
|
|
||||||
childBox.x1 = 0;
|
|
||||||
childBox.x2 = cornerWidth;
|
|
||||||
childBox.y1 = allocHeight;
|
|
||||||
childBox.y2 = allocHeight + cornerHeight;
|
|
||||||
this._leftCorner.actor.allocate(childBox, flags);
|
|
||||||
|
|
||||||
[cornerMinWidth, cornerWidth] = this._rightCorner.actor.get_preferred_width(-1);
|
|
||||||
[cornerMinHeight, cornerHeight] = this._rightCorner.actor.get_preferred_height(-1);
|
|
||||||
childBox.x1 = allocWidth - cornerWidth;
|
|
||||||
childBox.x2 = allocWidth;
|
|
||||||
childBox.y1 = allocHeight;
|
|
||||||
childBox.y2 = allocHeight + cornerHeight;
|
|
||||||
this._rightCorner.actor.allocate(childBox, flags);
|
|
||||||
},
|
|
||||||
|
|
||||||
_onButtonPress: function(actor, event) {
|
_onButtonPress: function(actor, event) {
|
||||||
if (event.get_source() != actor)
|
if (event.get_source() != actor)
|
||||||
return false;
|
return false;
|
||||||
|
@ -404,9 +404,17 @@ const PopupSeparatorMenuItem = new Lang.Class({
|
|||||||
this.parent({ reactive: false,
|
this.parent({ reactive: false,
|
||||||
can_focus: false});
|
can_focus: false});
|
||||||
|
|
||||||
this._drawingArea = new St.DrawingArea({ style_class: 'popup-separator-menu-item' });
|
this._separator = new HorzSeparator({ style_class: 'popup-separator-menu-item' });
|
||||||
this.addActor(this._drawingArea, { span: -1, expand: true });
|
this.addActor(this._separator.actor, { span: -1, expand: true });
|
||||||
this._drawingArea.connect('repaint', Lang.bind(this, this._onRepaint));
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const HorzSeparator = new Lang.Class({
|
||||||
|
Name: 'HorzSeparator',
|
||||||
|
|
||||||
|
_init: function (params) {
|
||||||
|
this.actor = new St.DrawingArea(params);
|
||||||
|
this.actor.connect('repaint', Lang.bind(this, this._onRepaint));
|
||||||
},
|
},
|
||||||
|
|
||||||
_onRepaint: function(area) {
|
_onRepaint: function(area) {
|
||||||
|
@ -27,6 +27,9 @@ const SearchProviderIface = <interface name="org.gnome.Shell.SearchProvider">
|
|||||||
<method name="ActivateResult">
|
<method name="ActivateResult">
|
||||||
<arg type="s" direction="in" />
|
<arg type="s" direction="in" />
|
||||||
</method>
|
</method>
|
||||||
|
<method name="LaunchSearch">
|
||||||
|
<arg type="as" direction="in" />
|
||||||
|
</method>
|
||||||
</interface>;
|
</interface>;
|
||||||
|
|
||||||
var SearchProviderProxy = Gio.DBusProxy.makeProxyWrapper(SearchProviderIface);
|
var SearchProviderProxy = Gio.DBusProxy.makeProxyWrapper(SearchProviderIface);
|
||||||
@ -38,22 +41,9 @@ function loadRemoteSearchProviders(addProviderCallback) {
|
|||||||
for (let i = 0; i < dataDirs.length; i++) {
|
for (let i = 0; i < dataDirs.length; i++) {
|
||||||
let path = GLib.build_filenamev([dataDirs[i], 'gnome-shell', 'search-providers']);
|
let path = GLib.build_filenamev([dataDirs[i], 'gnome-shell', 'search-providers']);
|
||||||
let dir = Gio.file_new_for_path(path);
|
let dir = Gio.file_new_for_path(path);
|
||||||
|
if (!dir.query_exists(null))
|
||||||
dir.query_info_async('standard:type', Gio.FileQueryInfoFlags.NONE,
|
continue;
|
||||||
GLib.PRIORITY_DEFAULT, null,
|
|
||||||
function(object, res) {
|
|
||||||
let exists = false;
|
|
||||||
try {
|
|
||||||
object.query_info_finish(res);
|
|
||||||
exists = true;
|
|
||||||
} catch (e) {
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!exists)
|
|
||||||
return;
|
|
||||||
|
|
||||||
loadRemoteSearchProvidersFromDir(dir, loadedProviders, addProviderCallback);
|
loadRemoteSearchProvidersFromDir(dir, loadedProviders, addProviderCallback);
|
||||||
});
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -73,7 +63,7 @@ function loadRemoteSearchProvidersFromDir(dir, loadedProviders, addProviderCallb
|
|||||||
if (!keyfile.has_group(KEY_FILE_GROUP))
|
if (!keyfile.has_group(KEY_FILE_GROUP))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
let remoteProvider;
|
let remoteProvider, title;
|
||||||
try {
|
try {
|
||||||
let group = KEY_FILE_GROUP;
|
let group = KEY_FILE_GROUP;
|
||||||
let busName = keyfile.get_string(group, 'BusName');
|
let busName = keyfile.get_string(group, 'BusName');
|
||||||
@ -87,17 +77,25 @@ function loadRemoteSearchProvidersFromDir(dir, loadedProviders, addProviderCallb
|
|||||||
let desktopId = keyfile.get_string(group, 'DesktopId');
|
let desktopId = keyfile.get_string(group, 'DesktopId');
|
||||||
appInfo = Gio.DesktopAppInfo.new(desktopId);
|
appInfo = Gio.DesktopAppInfo.new(desktopId);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
log('Ignoring search provider ' + path + ': missing DesktopId');
|
|
||||||
continue;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
remoteProvider = new RemoteSearchProvider(appInfo.get_name(),
|
let icon;
|
||||||
appInfo.get_icon(),
|
if (appInfo) {
|
||||||
|
icon = appInfo.get_icon();
|
||||||
|
title = appInfo.get_name();
|
||||||
|
} else {
|
||||||
|
let iconName = keyfile.get_string(group, 'Icon');
|
||||||
|
icon = new Gio.ThemedIcon({ name: iconName });
|
||||||
|
title = keyfile.get_locale_string(group, 'Title', null);
|
||||||
|
}
|
||||||
|
|
||||||
|
remoteProvider = new RemoteSearchProvider(title,
|
||||||
|
icon,
|
||||||
busName,
|
busName,
|
||||||
objectPath);
|
objectPath);
|
||||||
loadedProviders[objectPath] = remoteProvider;
|
loadedProviders[objectPath] = remoteProvider;
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
log('Failed to add search provider %s: %s'.format(path, e.toString()));
|
log('Failed to add search provider "%s": %s'.format(title, e.toString()));
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -113,14 +111,11 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
|
|
||||||
_init: function(title, icon, dbusName, dbusPath) {
|
_init: function(title, icon, dbusName, dbusPath) {
|
||||||
this._proxy = new SearchProviderProxy(Gio.DBus.session,
|
this._proxy = new SearchProviderProxy(Gio.DBus.session,
|
||||||
dbusName, dbusPath, Lang.bind(this, this._onProxyConstructed));
|
dbusName, dbusPath);
|
||||||
|
|
||||||
this.parent(title.toUpperCase());
|
this.parent(title.toUpperCase());
|
||||||
this._cancellable = new Gio.Cancellable();
|
this._cancellable = new Gio.Cancellable();
|
||||||
},
|
this.icon = icon;
|
||||||
|
|
||||||
_onProxyConstructed: function(proxy) {
|
|
||||||
// Do nothing
|
|
||||||
},
|
},
|
||||||
|
|
||||||
createIcon: function(size, meta) {
|
createIcon: function(size, meta) {
|
||||||
@ -135,9 +130,7 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
width, height, rowStride, size);
|
width, height, rowStride, size);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ugh, but we want to fall back to something ...
|
return null;
|
||||||
return new St.Icon({ icon_name: 'text-x-generic',
|
|
||||||
icon_size: size });
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_getResultsFinished: function(results, error) {
|
_getResultsFinished: function(results, error) {
|
||||||
@ -205,6 +198,10 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
|
|
||||||
activateResult: function(id) {
|
activateResult: function(id) {
|
||||||
this._proxy.ActivateResultRemote(id);
|
this._proxy.ActivateResultRemote(id);
|
||||||
|
},
|
||||||
|
|
||||||
|
launchSearch: function(terms) {
|
||||||
|
this._proxy.LaunchSearchRemote(terms);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -49,38 +49,6 @@ const SUMMARY_ICON_SIZE = 48;
|
|||||||
const STANDARD_FADE_TIME = 10;
|
const STANDARD_FADE_TIME = 10;
|
||||||
const SHORT_FADE_TIME = 0.3;
|
const SHORT_FADE_TIME = 0.3;
|
||||||
|
|
||||||
function sample(offx, offy) {
|
|
||||||
return 'texel += texture2D (sampler, tex_coord.st + pixel_step * ' +
|
|
||||||
'vec2 (' + offx + ',' + offy + ') * 2.0);\n'
|
|
||||||
}
|
|
||||||
const GLSL_BLUR_EFFECT_DECLARATIONS = ' \
|
|
||||||
uniform vec2 pixel_step;\n \
|
|
||||||
vec4 apply_blur(in sampler2D sampler, in vec2 tex_coord) {\n \
|
|
||||||
vec4 texel;\n \
|
|
||||||
texel = texture2D (sampler, tex_coord.st);\n'
|
|
||||||
+ sample(-1.0, -1.0)
|
|
||||||
+ sample( 0.0, -1.0)
|
|
||||||
+ sample(+1.0, -1.0)
|
|
||||||
+ sample(-1.0, 0.0)
|
|
||||||
+ sample( 0.0, 0.0)
|
|
||||||
+ sample(+1.0, 0.0)
|
|
||||||
+ sample(-1.0, +1.0)
|
|
||||||
+ sample( 0.0, +1.0)
|
|
||||||
+ sample(+1.0, +1.0) + ' \
|
|
||||||
texel /= 9.0;\n \
|
|
||||||
return texel;\n \
|
|
||||||
}\n \
|
|
||||||
vec3 desaturate (const vec3 color, const float desaturation)\n \
|
|
||||||
{\n \
|
|
||||||
const vec3 gray_conv = vec3 (0.299, 0.587, 0.114);\n \
|
|
||||||
vec3 gray = vec3 (dot (gray_conv, color));\n \
|
|
||||||
return vec3 (mix (color.rgb, gray, desaturation));\n \
|
|
||||||
}';
|
|
||||||
const GLSL_BLUR_EFFECT_CODE = ' \
|
|
||||||
cogl_texel = apply_blur(cogl_sampler, cogl_tex_coord.st);\n \
|
|
||||||
cogl_texel.rgb = desaturate(cogl_texel.rgb, 0.6);\n';
|
|
||||||
|
|
||||||
|
|
||||||
const Clock = new Lang.Class({
|
const Clock = new Lang.Class({
|
||||||
Name: 'ScreenShieldClock',
|
Name: 'ScreenShieldClock',
|
||||||
|
|
||||||
@ -367,10 +335,6 @@ const Arrow = new Lang.Class({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
function clamp(value, min, max) {
|
|
||||||
return Math.max(min, Math.min(max, value));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* To test screen shield, make sure to kill gnome-screensaver.
|
* To test screen shield, make sure to kill gnome-screensaver.
|
||||||
*
|
*
|
||||||
@ -403,13 +367,8 @@ const ScreenShield = new Lang.Class({
|
|||||||
name: 'lockScreenContents' });
|
name: 'lockScreenContents' });
|
||||||
this._lockScreenContents.add_constraint(new Layout.MonitorConstraint({ primary: true }));
|
this._lockScreenContents.add_constraint(new Layout.MonitorConstraint({ primary: true }));
|
||||||
|
|
||||||
let backgroundActor = Meta.BackgroundActor.new_for_screen(global.screen);
|
|
||||||
backgroundActor.add_glsl_snippet(Meta.SnippetHook.TEXTURE_LOOKUP,
|
|
||||||
GLSL_BLUR_EFFECT_DECLARATIONS,
|
|
||||||
GLSL_BLUR_EFFECT_CODE,
|
|
||||||
true);
|
|
||||||
this._background = new St.Bin({ style_class: 'screen-shield-background',
|
this._background = new St.Bin({ style_class: 'screen-shield-background',
|
||||||
child: backgroundActor });
|
child: Meta.BackgroundActor.new_for_screen(global.screen) });
|
||||||
this._lockScreenGroup.add_actor(this._background);
|
this._lockScreenGroup.add_actor(this._background);
|
||||||
this._lockScreenGroup.add_actor(this._lockScreenContents);
|
this._lockScreenGroup.add_actor(this._lockScreenContents);
|
||||||
|
|
||||||
@ -428,11 +387,14 @@ const ScreenShield = new Lang.Class({
|
|||||||
}
|
}
|
||||||
this._lockScreenContents.add_actor(this._arrowContainer);
|
this._lockScreenContents.add_actor(this._arrowContainer);
|
||||||
|
|
||||||
this._dragAction = new Clutter.GestureAction();
|
let dragArea = new Clutter.Rect({ origin: new Clutter.Point({ x: 0, y: -global.screen_height, }),
|
||||||
this._dragAction.connect('gesture-begin', Lang.bind(this, this._onDragBegin));
|
size: new Clutter.Size({ width: global.screen_width,
|
||||||
this._dragAction.connect('gesture-progress', Lang.bind(this, this._onDragMotion));
|
height: global.screen_height }) });
|
||||||
this._dragAction.connect('gesture-end', Lang.bind(this, this._onDragEnd));
|
let action = new Clutter.DragAction({ drag_axis: Clutter.DragAxis.Y_AXIS,
|
||||||
this._lockScreenGroup.add_action(this._dragAction);
|
drag_area: dragArea });
|
||||||
|
action.connect('drag-begin', Lang.bind(this, this._onDragBegin));
|
||||||
|
action.connect('drag-end', Lang.bind(this, this._onDragEnd));
|
||||||
|
this._lockScreenGroup.add_action(action);
|
||||||
|
|
||||||
this._lockDialogGroup = new St.Widget({ x_expand: true,
|
this._lockDialogGroup = new St.Widget({ x_expand: true,
|
||||||
y_expand: true,
|
y_expand: true,
|
||||||
@ -474,8 +436,6 @@ const ScreenShield = new Lang.Class({
|
|||||||
{ inhibitEvents: true,
|
{ inhibitEvents: true,
|
||||||
fadeInTime: STANDARD_FADE_TIME,
|
fadeInTime: STANDARD_FADE_TIME,
|
||||||
fadeFactor: 1 });
|
fadeFactor: 1 });
|
||||||
|
|
||||||
this.idleMonitor = new GnomeDesktop.IdleMonitor();
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_onLockScreenKeyRelease: function(actor, event) {
|
_onLockScreenKeyRelease: function(actor, event) {
|
||||||
@ -496,7 +456,7 @@ const ScreenShield = new Lang.Class({
|
|||||||
symbol == Clutter.KEY_Return ||
|
symbol == Clutter.KEY_Return ||
|
||||||
symbol == Clutter.KEY_KP_Enter) {
|
symbol == Clutter.KEY_KP_Enter) {
|
||||||
this._ensureUnlockDialog(true);
|
this._ensureUnlockDialog(true);
|
||||||
this._hideLockScreen(true, 0);
|
this._hideLockScreen(true);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -519,7 +479,7 @@ const ScreenShield = new Lang.Class({
|
|||||||
// 7 standard scrolls to lift up
|
// 7 standard scrolls to lift up
|
||||||
if (this._lockScreenScrollCounter > 35) {
|
if (this._lockScreenScrollCounter > 35) {
|
||||||
this._ensureUnlockDialog(false);
|
this._ensureUnlockDialog(false);
|
||||||
this._hideLockScreen(true, 0);
|
this._hideLockScreen(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -551,27 +511,12 @@ const ScreenShield = new Lang.Class({
|
|||||||
Tweener.removeTweens(this._lockScreenGroup);
|
Tweener.removeTweens(this._lockScreenGroup);
|
||||||
this._lockScreenState = MessageTray.State.HIDING;
|
this._lockScreenState = MessageTray.State.HIDING;
|
||||||
this._ensureUnlockDialog(false);
|
this._ensureUnlockDialog(false);
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
_onDragMotion: function() {
|
|
||||||
let [origX, origY] = this._dragAction.get_press_coords(0);
|
|
||||||
let [currentX, currentY] = this._dragAction.get_motion_coords(0);
|
|
||||||
|
|
||||||
let newY = currentY - origY;
|
|
||||||
newY = clamp(newY, -global.stage.height, 0);
|
|
||||||
|
|
||||||
this._lockScreenGroup.y = newY;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_onDragEnd: function(action, actor, eventX, eventY, modifiers) {
|
_onDragEnd: function(action, actor, eventX, eventY, modifiers) {
|
||||||
if (this._lockScreenGroup.y < -(ARROW_DRAG_THRESHOLD * global.stage.height)) {
|
if (this._lockScreenGroup.y < -(ARROW_DRAG_THRESHOLD * global.stage.height)) {
|
||||||
// Complete motion automatically
|
// Complete motion automatically
|
||||||
let [velocity, velocityX, velocityY] = this._dragAction.get_velocity(0);
|
this._hideLockScreen(true);
|
||||||
this._hideLockScreen(true, -velocityY);
|
|
||||||
} else {
|
} else {
|
||||||
// restore the lock screen to its original place
|
// restore the lock screen to its original place
|
||||||
// try to use the same speed as the normal animation
|
// try to use the same speed as the normal animation
|
||||||
@ -600,9 +545,7 @@ const ScreenShield = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onStatusChanged: function(status) {
|
_onStatusChanged: function(status) {
|
||||||
if (status != GnomeSession.PresenceStatus.IDLE)
|
if (status == GnomeSession.PresenceStatus.IDLE) {
|
||||||
return;
|
|
||||||
|
|
||||||
if (this._dialog) {
|
if (this._dialog) {
|
||||||
this._dialog.cancel();
|
this._dialog.cancel();
|
||||||
if (!this._isGreeter) {
|
if (!this._isGreeter) {
|
||||||
@ -620,23 +563,17 @@ const ScreenShield = new Lang.Class({
|
|||||||
|
|
||||||
if (this._activationTime == 0)
|
if (this._activationTime == 0)
|
||||||
this._activationTime = GLib.get_monotonic_time();
|
this._activationTime = GLib.get_monotonic_time();
|
||||||
|
}
|
||||||
this._becameActiveId = this.idleMonitor.connect('became-active', Lang.bind(this, function() {
|
} else {
|
||||||
this.idleMonitor.disconnect(this._becameActiveId);
|
|
||||||
|
|
||||||
let lightboxWasShown = this._lightbox.shown;
|
let lightboxWasShown = this._lightbox.shown;
|
||||||
this._lightbox.hide();
|
this._lightbox.hide();
|
||||||
|
|
||||||
let shouldLock = lightboxWasShown && this._settings.get_boolean(LOCK_ENABLED_KEY);
|
let shouldLock = lightboxWasShown && this._settings.get_boolean(LOCK_ENABLED_KEY);
|
||||||
if (shouldLock || this._isLocked) {
|
if (shouldLock || this._isActive) {
|
||||||
this.lock(false);
|
this.lock(false);
|
||||||
} else if (this._isActive) {
|
} else if (this._isModal) {
|
||||||
this.unlock();
|
this.unlock();
|
||||||
}
|
}
|
||||||
}));
|
|
||||||
|
|
||||||
this._isActive = true;
|
|
||||||
this.emit('lock-status-changed');
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -655,7 +592,7 @@ const ScreenShield = new Lang.Class({
|
|||||||
this.actor.show();
|
this.actor.show();
|
||||||
this._isGreeter = Main.sessionMode.isGreeter;
|
this._isGreeter = Main.sessionMode.isGreeter;
|
||||||
this._ensureUnlockDialog(true);
|
this._ensureUnlockDialog(true);
|
||||||
this._hideLockScreen(false, 0);
|
this._hideLockScreen(false);
|
||||||
},
|
},
|
||||||
|
|
||||||
_bumpLockScreen: function() {
|
_bumpLockScreen: function() {
|
||||||
@ -673,21 +610,14 @@ const ScreenShield = new Lang.Class({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
_hideLockScreen: function(animate, velocity) {
|
_hideLockScreen: function(animate) {
|
||||||
this._lockScreenState = MessageTray.State.HIDING;
|
this._lockScreenState = MessageTray.State.HIDING;
|
||||||
|
|
||||||
if (animate) {
|
if (animate) {
|
||||||
// Tween the lock screen out of screen
|
// Tween the lock screen out of screen
|
||||||
// if velocity is not specified (i.e. we come here from pressing ESC),
|
// try to use the same speed regardless of original position
|
||||||
// use the same speed regardless of original position
|
|
||||||
// if velocity is specified, it's in pixels per milliseconds
|
|
||||||
let h = global.stage.height;
|
let h = global.stage.height;
|
||||||
let delta = (h + this._lockScreenGroup.y);
|
let time = CURTAIN_SLIDE_TIME * (h + this._lockScreenGroup.y) / h;
|
||||||
let min_velocity = global.stage.height / (CURTAIN_SLIDE_TIME * 1000);
|
|
||||||
|
|
||||||
velocity = Math.max(min_velocity, velocity);
|
|
||||||
let time = (delta / velocity) / 1000;
|
|
||||||
|
|
||||||
Tweener.removeTweens(this._lockScreenGroup);
|
Tweener.removeTweens(this._lockScreenGroup);
|
||||||
Tweener.addTween(this._lockScreenGroup,
|
Tweener.addTween(this._lockScreenGroup,
|
||||||
{ y: -h,
|
{ y: -h,
|
||||||
@ -704,8 +634,6 @@ const ScreenShield = new Lang.Class({
|
|||||||
this._lockScreenGroup.hide();
|
this._lockScreenGroup.hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
global.stage.show_cursor();
|
|
||||||
|
|
||||||
if (Main.sessionMode.currentMode == 'lock-screen')
|
if (Main.sessionMode.currentMode == 'lock-screen')
|
||||||
Main.sessionMode.popMode('lock-screen');
|
Main.sessionMode.popMode('lock-screen');
|
||||||
},
|
},
|
||||||
@ -794,16 +722,6 @@ const ScreenShield = new Lang.Class({
|
|||||||
this._arrowAnimationId = Mainloop.timeout_add(6000, Lang.bind(this, this._animateArrows));
|
this._arrowAnimationId = Mainloop.timeout_add(6000, Lang.bind(this, this._animateArrows));
|
||||||
this._animateArrows();
|
this._animateArrows();
|
||||||
|
|
||||||
let motionId = global.stage.connect('captured-event', function(stage, event) {
|
|
||||||
if (event.type() == Clutter.EventType.MOTION) {
|
|
||||||
global.stage.show_cursor();
|
|
||||||
global.stage.disconnect(motionId);
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
});
|
|
||||||
global.stage.hide_cursor();
|
|
||||||
|
|
||||||
this._lockScreenState = MessageTray.State.SHOWN;
|
this._lockScreenState = MessageTray.State.SHOWN;
|
||||||
this._lockScreenGroup.fixed_position_set = false;
|
this._lockScreenGroup.fixed_position_set = false;
|
||||||
this._lockScreenScrollCounter = 0;
|
this._lockScreenScrollCounter = 0;
|
||||||
@ -912,7 +830,6 @@ const ScreenShield = new Lang.Class({
|
|||||||
|
|
||||||
this._activationTime = 0;
|
this._activationTime = 0;
|
||||||
this._isActive = false;
|
this._isActive = false;
|
||||||
this._isLocked = false;
|
|
||||||
this.emit('lock-status-changed');
|
this.emit('lock-status-changed');
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -937,7 +854,6 @@ const ScreenShield = new Lang.Class({
|
|||||||
this._resetLockScreen(animate, animate);
|
this._resetLockScreen(animate, animate);
|
||||||
|
|
||||||
this._isActive = true;
|
this._isActive = true;
|
||||||
this._isLocked = true;
|
|
||||||
this.emit('lock-status-changed');
|
this.emit('lock-status-changed');
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
@ -163,6 +163,16 @@ const SearchProvider = new Lang.Class({
|
|||||||
*/
|
*/
|
||||||
activateResult: function(id) {
|
activateResult: function(id) {
|
||||||
throw new Error('Not implemented');
|
throw new Error('Not implemented');
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* launchSearch:
|
||||||
|
* @terms: Current search terms
|
||||||
|
*
|
||||||
|
* Called when the user clicks the provider icon.
|
||||||
|
*/
|
||||||
|
launchSearch: function(terms) {
|
||||||
|
throw new Error('Not implemented');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(SearchProvider.prototype);
|
Signals.addSignalMethods(SearchProvider.prototype);
|
||||||
@ -261,5 +271,11 @@ const SearchSystem = new Lang.Class({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
launchSearch: function(provider) {
|
||||||
|
let terms = this.getTerms();
|
||||||
|
provider.launchSearch(terms);
|
||||||
|
Main.overview.toggle();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(SearchSystem.prototype);
|
Signals.addSignalMethods(SearchSystem.prototype);
|
||||||
|
@ -4,25 +4,191 @@ const Clutter = imports.gi.Clutter;
|
|||||||
const Lang = imports.lang;
|
const Lang = imports.lang;
|
||||||
const Gtk = imports.gi.Gtk;
|
const Gtk = imports.gi.Gtk;
|
||||||
const Meta = imports.gi.Meta;
|
const Meta = imports.gi.Meta;
|
||||||
|
const Signals = imports.signals;
|
||||||
const St = imports.gi.St;
|
const St = imports.gi.St;
|
||||||
const Atk = imports.gi.Atk;
|
const Atk = imports.gi.Atk;
|
||||||
|
|
||||||
|
const AppDisplay = imports.ui.appDisplay;
|
||||||
const DND = imports.ui.dnd;
|
const DND = imports.ui.dnd;
|
||||||
const IconGrid = imports.ui.iconGrid;
|
const IconGrid = imports.ui.iconGrid;
|
||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
const Overview = imports.ui.overview;
|
const Overview = imports.ui.overview;
|
||||||
|
const PopupMenu = imports.ui.popupMenu;
|
||||||
const Search = imports.ui.search;
|
const Search = imports.ui.search;
|
||||||
|
|
||||||
const MAX_SEARCH_RESULTS_ROWS = 1;
|
const MAX_SEARCH_RESULTS_ROWS = 3;
|
||||||
|
const MAX_GRID_SEARCH_RESULTS_ROWS = 1;
|
||||||
|
|
||||||
|
|
||||||
const SearchResult = new Lang.Class({
|
const ListSearchResult = new Lang.Class({
|
||||||
Name: 'SearchResult',
|
Name: 'ListSearchResult',
|
||||||
|
|
||||||
|
ICON_SIZE: 64,
|
||||||
|
|
||||||
_init: function(provider, metaInfo, terms) {
|
_init: function(provider, metaInfo, terms) {
|
||||||
this.provider = provider;
|
this.provider = provider;
|
||||||
this.metaInfo = metaInfo;
|
this.metaInfo = metaInfo;
|
||||||
this.actor = new St.Button({ style_class: 'search-result',
|
this.actor = new St.Button({ style_class: 'search-result',
|
||||||
|
reactive: true,
|
||||||
|
can_focus: true,
|
||||||
|
track_hover: true,
|
||||||
|
x_align: St.Align.START,
|
||||||
|
x_fill: true,
|
||||||
|
y_fill: true });
|
||||||
|
this.actor._delegate = this;
|
||||||
|
|
||||||
|
let content = new St.BoxLayout({ style_class: 'search-result-content',
|
||||||
|
vertical: false });
|
||||||
|
this._content = content;
|
||||||
|
this.actor.set_child(content);
|
||||||
|
|
||||||
|
// An icon for, or thumbnail of, content
|
||||||
|
let icon = this.metaInfo['createIcon'](this.ICON_SIZE);
|
||||||
|
if (icon) {
|
||||||
|
let iconBin = new St.Bin({ style_class: 'search-result-icon',
|
||||||
|
child: icon });
|
||||||
|
content.add(iconBin);
|
||||||
|
}
|
||||||
|
|
||||||
|
let details = new St.BoxLayout({ style_class: 'search-result-details',
|
||||||
|
vertical: true });
|
||||||
|
content.add(details, { x_fill: true,
|
||||||
|
y_fill: false,
|
||||||
|
x_align: St.Align.START,
|
||||||
|
y_align: St.Align.MIDDLE });
|
||||||
|
|
||||||
|
let title = new St.Label({ style_class: 'search-result-details-title',
|
||||||
|
text: this.metaInfo['name'] })
|
||||||
|
details.add(title, { x_fill: true,
|
||||||
|
y_fill: false,
|
||||||
|
x_align: St.Align.START,
|
||||||
|
y_align: St.Align.START });
|
||||||
|
|
||||||
|
// TODO: could highlight terms in the description here, or should
|
||||||
|
// providers provide what should be highlighted?
|
||||||
|
if (this.metaInfo['description']) {
|
||||||
|
let description = new St.Label({ style_class: 'search-result-details-description',
|
||||||
|
text: this.metaInfo['description'] });
|
||||||
|
details.add(description, { x_fill: false,
|
||||||
|
y_fill: true,
|
||||||
|
x_align: St.Align.START,
|
||||||
|
y_align: St.Align.END });
|
||||||
|
}
|
||||||
|
|
||||||
|
this.actor.connect('clicked', Lang.bind(this, this._onResultClicked));
|
||||||
|
},
|
||||||
|
|
||||||
|
setSelected: function(selected) {
|
||||||
|
if (selected)
|
||||||
|
this.actor.add_style_pseudo_class('selected');
|
||||||
|
else
|
||||||
|
this.actor.remove_style_pseudo_class('selected');
|
||||||
|
},
|
||||||
|
|
||||||
|
activate: function() {
|
||||||
|
this.provider.activateResult(this.metaInfo.id);
|
||||||
|
Main.overview.toggle();
|
||||||
|
},
|
||||||
|
|
||||||
|
_onResultClicked: function(actor) {
|
||||||
|
this.activate();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
const ListSearchResults = new Lang.Class({
|
||||||
|
Name: 'ListSearchResults',
|
||||||
|
Extends: Search.SearchResultDisplay,
|
||||||
|
|
||||||
|
_init: function(provider) {
|
||||||
|
this.parent(provider);
|
||||||
|
|
||||||
|
this.actor = new St.BoxLayout({ style_class: 'results-list',
|
||||||
|
vertical: true });
|
||||||
|
this.actor.connect('notify::width', Lang.bind(this, function() {
|
||||||
|
Meta.later_add(Meta.LaterType.BEFORE_REDRAW, Lang.bind(this, function() {
|
||||||
|
let results = this.getResultsForDisplay();
|
||||||
|
if (results.length == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
|
provider.getResultMetas(results, Lang.bind(this, this.renderResults));
|
||||||
|
}));
|
||||||
|
}));
|
||||||
|
this._notDisplayedResult = [];
|
||||||
|
this._terms = [];
|
||||||
|
this._pendingClear = false;
|
||||||
|
},
|
||||||
|
|
||||||
|
getResultsForDisplay: function() {
|
||||||
|
let alreadyVisible = this._pendingClear ? 0 : this.getVisibleResultCount();
|
||||||
|
let canDisplay = MAX_SEARCH_RESULTS_ROWS - alreadyVisible;
|
||||||
|
|
||||||
|
let numResults = Math.min(this._notDisplayedResult.length, canDisplay);
|
||||||
|
|
||||||
|
return this._notDisplayedResult.splice(0, numResults);
|
||||||
|
},
|
||||||
|
|
||||||
|
getVisibleResultCount: function() {
|
||||||
|
return this.actor.get_n_children();
|
||||||
|
},
|
||||||
|
|
||||||
|
hasMoreResults: function() {
|
||||||
|
return this._notDisplayedResult.length > 0;
|
||||||
|
},
|
||||||
|
|
||||||
|
setResults: function(results, terms) {
|
||||||
|
// copy the lists
|
||||||
|
this._notDisplayedResult = results.slice(0);
|
||||||
|
this._terms = terms.slice(0);
|
||||||
|
this._pendingClear = true;
|
||||||
|
},
|
||||||
|
|
||||||
|
renderResults: function(metas) {
|
||||||
|
for (let i = 0; i < metas.length; i++) {
|
||||||
|
let display = new ListSearchResult(this.provider, metas[i], this._terms);
|
||||||
|
this.addItem(display.actor);
|
||||||
|
|
||||||
|
display.actor.connect('key-focus-in', Lang.bind(this, this._onFocusedProviderChanged));
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
clear: function () {
|
||||||
|
this.actor.destroy_all_children();
|
||||||
|
this._pendingClear = false;
|
||||||
|
},
|
||||||
|
|
||||||
|
getFirstResult: function() {
|
||||||
|
if (this.getVisibleResultCount() > 0)
|
||||||
|
return this.getItemAtIndex(0)._delegate;
|
||||||
|
else
|
||||||
|
return null;
|
||||||
|
},
|
||||||
|
|
||||||
|
addItem: function(actor, index) {
|
||||||
|
if (index !== undefined)
|
||||||
|
this.actor.insert_child_at_index(actor, index);
|
||||||
|
else
|
||||||
|
this.actor.add_actor(actor);
|
||||||
|
},
|
||||||
|
|
||||||
|
getItemAtIndex: function(index) {
|
||||||
|
return this.actor.get_child_at_index(index);
|
||||||
|
},
|
||||||
|
|
||||||
|
_onFocusedProviderChanged: function() {
|
||||||
|
this.emit('focused-provider-changed');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Signals.addSignalMethods(ListSearchResults.prototype);
|
||||||
|
|
||||||
|
|
||||||
|
const GridSearchResult = new Lang.Class({
|
||||||
|
Name: 'GridSearchResult',
|
||||||
|
|
||||||
|
_init: function(provider, metaInfo, terms) {
|
||||||
|
this.provider = provider;
|
||||||
|
this.metaInfo = metaInfo;
|
||||||
|
this.actor = new St.Button({ style_class: 'grid-search-result',
|
||||||
reactive: true,
|
reactive: true,
|
||||||
x_align: St.Align.START,
|
x_align: St.Align.START,
|
||||||
y_fill: true });
|
y_fill: true });
|
||||||
@ -31,7 +197,7 @@ const SearchResult = new Lang.Class({
|
|||||||
|
|
||||||
let content = provider.createResultActor(metaInfo, terms);
|
let content = provider.createResultActor(metaInfo, terms);
|
||||||
if (content == null) {
|
if (content == null) {
|
||||||
content = new St.Bin({ style_class: 'search-result-content',
|
content = new St.Bin({ style_class: 'grid-search-result-content',
|
||||||
reactive: true,
|
reactive: true,
|
||||||
can_focus: true,
|
can_focus: true,
|
||||||
track_hover: true,
|
track_hover: true,
|
||||||
@ -45,7 +211,7 @@ const SearchResult = new Lang.Class({
|
|||||||
if (content._delegate && content._delegate.getDragActorSource)
|
if (content._delegate && content._delegate.getDragActorSource)
|
||||||
this._dragActorSource = content._delegate.getDragActorSource();
|
this._dragActorSource = content._delegate.getDragActorSource();
|
||||||
}
|
}
|
||||||
this._content = content;
|
this.content = content;
|
||||||
this.actor.set_child(content);
|
this.actor.set_child(content);
|
||||||
|
|
||||||
this.actor.connect('clicked', Lang.bind(this, this._onResultClicked));
|
this.actor.connect('clicked', Lang.bind(this, this._onResultClicked));
|
||||||
@ -53,23 +219,23 @@ const SearchResult = new Lang.Class({
|
|||||||
let draggable = DND.makeDraggable(this.actor);
|
let draggable = DND.makeDraggable(this.actor);
|
||||||
draggable.connect('drag-begin',
|
draggable.connect('drag-begin',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
Main.overview.beginItemDrag(this);
|
Main.overview.beginAppDrag(this);
|
||||||
}));
|
}));
|
||||||
draggable.connect('drag-cancelled',
|
draggable.connect('drag-cancelled',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
Main.overview.cancelledItemDrag(this);
|
Main.overview.cancelledAppDrag(this);
|
||||||
}));
|
}));
|
||||||
draggable.connect('drag-end',
|
draggable.connect('drag-end',
|
||||||
Lang.bind(this, function() {
|
Lang.bind(this, function() {
|
||||||
Main.overview.endItemDrag(this);
|
Main.overview.endAppDrag(this);
|
||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
|
|
||||||
setSelected: function(selected) {
|
setSelected: function(selected) {
|
||||||
if (selected)
|
if (selected)
|
||||||
this._content.add_style_pseudo_class('selected');
|
this.content.add_style_pseudo_class('selected');
|
||||||
else
|
else
|
||||||
this._content.remove_style_pseudo_class('selected');
|
this.content.remove_style_pseudo_class('selected');
|
||||||
},
|
},
|
||||||
|
|
||||||
activate: function() {
|
activate: function() {
|
||||||
@ -85,7 +251,7 @@ const SearchResult = new Lang.Class({
|
|||||||
if (this._dragActorSource)
|
if (this._dragActorSource)
|
||||||
return this._dragActorSource;
|
return this._dragActorSource;
|
||||||
// not exactly right, but alignment problems are hard to notice
|
// not exactly right, but alignment problems are hard to notice
|
||||||
return this._content;
|
return this.content;
|
||||||
},
|
},
|
||||||
|
|
||||||
getDragActor: function(stageX, stageY) {
|
getDragActor: function(stageX, stageY) {
|
||||||
@ -108,11 +274,11 @@ const GridSearchResults = new Lang.Class({
|
|||||||
_init: function(provider, grid) {
|
_init: function(provider, grid) {
|
||||||
this.parent(provider);
|
this.parent(provider);
|
||||||
|
|
||||||
this._grid = grid || new IconGrid.IconGrid({ rowLimit: MAX_SEARCH_RESULTS_ROWS,
|
this._grid = grid || new IconGrid.IconGrid({ rowLimit: MAX_GRID_SEARCH_RESULTS_ROWS,
|
||||||
xAlign: St.Align.START });
|
xAlign: St.Align.START });
|
||||||
this.actor = new St.Bin({ x_align: St.Align.START });
|
this.actor = new St.Bin({ x_align: St.Align.MIDDLE });
|
||||||
|
|
||||||
this.actor.set_child(this._grid.actor);
|
this.actor.set_child(this._grid.actor);
|
||||||
|
|
||||||
this._width = 0;
|
this._width = 0;
|
||||||
this.actor.connect('notify::width', Lang.bind(this, function() {
|
this.actor.connect('notify::width', Lang.bind(this, function() {
|
||||||
this._width = this.actor.width;
|
this._width = this.actor.width;
|
||||||
@ -130,6 +296,7 @@ const GridSearchResults = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
getResultsForDisplay: function() {
|
getResultsForDisplay: function() {
|
||||||
|
this._grid.actor.ensure_style();
|
||||||
let alreadyVisible = this._pendingClear ? 0 : this._grid.visibleItemsCount();
|
let alreadyVisible = this._pendingClear ? 0 : this._grid.visibleItemsCount();
|
||||||
let canDisplay = this._grid.childrenInRow(this._width) * this._grid.getRowLimit()
|
let canDisplay = this._grid.childrenInRow(this._width) * this._grid.getRowLimit()
|
||||||
- alreadyVisible;
|
- alreadyVisible;
|
||||||
@ -143,6 +310,10 @@ const GridSearchResults = new Lang.Class({
|
|||||||
return this._grid.visibleItemsCount();
|
return this._grid.visibleItemsCount();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
hasMoreResults: function() {
|
||||||
|
return this._notDisplayedResult.length > 0;
|
||||||
|
},
|
||||||
|
|
||||||
setResults: function(results, terms) {
|
setResults: function(results, terms) {
|
||||||
// copy the lists
|
// copy the lists
|
||||||
this._notDisplayedResult = results.slice(0);
|
this._notDisplayedResult = results.slice(0);
|
||||||
@ -152,8 +323,10 @@ const GridSearchResults = new Lang.Class({
|
|||||||
|
|
||||||
renderResults: function(metas) {
|
renderResults: function(metas) {
|
||||||
for (let i = 0; i < metas.length; i++) {
|
for (let i = 0; i < metas.length; i++) {
|
||||||
let display = new SearchResult(this.provider, metas[i], this._terms);
|
let display = new GridSearchResult(this.provider, metas[i], this._terms);
|
||||||
this._grid.addItem(display.actor);
|
this._grid.addItem(display.actor);
|
||||||
|
|
||||||
|
display.content.connect('key-focus-in', Lang.bind(this, this._onFocusedProviderChanged));
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -167,11 +340,17 @@ const GridSearchResults = new Lang.Class({
|
|||||||
return this._grid.getItemAtIndex(0)._delegate;
|
return this._grid.getItemAtIndex(0)._delegate;
|
||||||
else
|
else
|
||||||
return null;
|
return null;
|
||||||
|
},
|
||||||
|
|
||||||
|
_onFocusedProviderChanged: function() {
|
||||||
|
this.emit('focused-provider-changed');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Signals.addSignalMethods(GridSearchResults.prototype);
|
||||||
|
|
||||||
const SearchResults = new Lang.Class({
|
|
||||||
Name: 'SearchResults',
|
const SearchDisplay = new Lang.Class({
|
||||||
|
Name: 'SearchDisplay',
|
||||||
|
|
||||||
_init: function(searchSystem) {
|
_init: function(searchSystem) {
|
||||||
this._searchSystem = searchSystem;
|
this._searchSystem = searchSystem;
|
||||||
@ -222,19 +401,43 @@ const SearchResults = new Lang.Class({
|
|||||||
createProviderMeta: function(provider) {
|
createProviderMeta: function(provider) {
|
||||||
let providerBox = new St.BoxLayout({ style_class: 'search-section',
|
let providerBox = new St.BoxLayout({ style_class: 'search-section',
|
||||||
vertical: true });
|
vertical: true });
|
||||||
let title = new St.Label({ style_class: 'search-section-header',
|
let providerBoxContent = new St.BoxLayout({ style_class: 'search-section-content' });
|
||||||
text: provider.title });
|
let isAppsProvider = (provider instanceof AppDisplay.AppSearchProvider);
|
||||||
providerBox.add(title, { x_fill: false, x_align: St.Align.START });
|
|
||||||
|
let providerIcon;
|
||||||
|
if (!isAppsProvider) {
|
||||||
|
let separator = new PopupMenu.HorzSeparator({ style_class: 'search-section-separator' });
|
||||||
|
providerBox.add(separator.actor, { expand: true });
|
||||||
|
|
||||||
|
providerIcon = new ProviderIcon(provider);
|
||||||
|
providerIcon.connect('launch-search', Lang.bind(this, function(providerIcon) {
|
||||||
|
this._searchSystem.launchSearch(providerIcon.provider);
|
||||||
|
}));
|
||||||
|
providerBoxContent.add(providerIcon.actor, { x_fill: false,
|
||||||
|
y_fill: false,
|
||||||
|
x_align: St.Align.START,
|
||||||
|
y_align: St.Align.START });
|
||||||
|
}
|
||||||
|
|
||||||
let resultDisplayBin = new St.Bin({ style_class: 'search-section-results',
|
let resultDisplayBin = new St.Bin({ style_class: 'search-section-results',
|
||||||
x_fill: true,
|
x_fill: true,
|
||||||
y_fill: true });
|
y_fill: true });
|
||||||
providerBox.add(resultDisplayBin, { expand: true });
|
providerBoxContent.add(resultDisplayBin, { expand: true });
|
||||||
let resultDisplay = new GridSearchResults(provider);
|
|
||||||
|
providerBox.add(providerBoxContent);
|
||||||
|
|
||||||
|
let resultDisplay;
|
||||||
|
if (isAppsProvider)
|
||||||
|
resultDisplay = new GridSearchResults(provider);
|
||||||
|
else
|
||||||
|
resultDisplay = new ListSearchResults(provider);
|
||||||
|
|
||||||
|
resultDisplay.connect('focused-provider-changed', Lang.bind(this, this._updateProviderIconCanFocus));
|
||||||
resultDisplayBin.set_child(resultDisplay.actor);
|
resultDisplayBin.set_child(resultDisplay.actor);
|
||||||
|
|
||||||
this._providerMeta.push({ provider: provider,
|
this._providerMeta.push({ provider: provider,
|
||||||
actor: providerBox,
|
actor: providerBox,
|
||||||
|
icon: providerIcon,
|
||||||
resultDisplay: resultDisplay });
|
resultDisplay: resultDisplay });
|
||||||
this._content.add(providerBox);
|
this._content.add(providerBox);
|
||||||
},
|
},
|
||||||
@ -255,6 +458,7 @@ const SearchResults = new Lang.Class({
|
|||||||
let meta = this._providerMeta[i];
|
let meta = this._providerMeta[i];
|
||||||
meta.resultDisplay.clear();
|
meta.resultDisplay.clear();
|
||||||
meta.actor.hide();
|
meta.actor.hide();
|
||||||
|
if (meta.icon) meta.icon.actor.can_focus = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -262,6 +466,7 @@ const SearchResults = new Lang.Class({
|
|||||||
let meta = this._metaForProvider(provider);
|
let meta = this._metaForProvider(provider);
|
||||||
meta.resultDisplay.clear();
|
meta.resultDisplay.clear();
|
||||||
meta.actor.hide();
|
meta.actor.hide();
|
||||||
|
if (meta.icon) meta.icon.actor.can_focus = false;
|
||||||
},
|
},
|
||||||
|
|
||||||
reset: function() {
|
reset: function() {
|
||||||
@ -284,6 +489,11 @@ const SearchResults = new Lang.Class({
|
|||||||
return this._providerMeta[this._providers.indexOf(provider)];
|
return this._providerMeta[this._providers.indexOf(provider)];
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_metaForProvidersExcept: function(provider) {
|
||||||
|
let skip = this._providers.indexOf(provider);
|
||||||
|
return this._providerMeta.filter(function(meta, index) { return index != skip }, this);
|
||||||
|
},
|
||||||
|
|
||||||
_maybeSetInitialSelection: function() {
|
_maybeSetInitialSelection: function() {
|
||||||
let newDefaultResult = null;
|
let newDefaultResult = null;
|
||||||
|
|
||||||
@ -341,6 +551,9 @@ const SearchResults = new Lang.Class({
|
|||||||
meta.resultDisplay.setResults(providerResults, terms);
|
meta.resultDisplay.setResults(providerResults, terms);
|
||||||
let results = meta.resultDisplay.getResultsForDisplay();
|
let results = meta.resultDisplay.getResultsForDisplay();
|
||||||
|
|
||||||
|
if (meta.icon)
|
||||||
|
meta.icon.moreIcon.visible = meta.resultDisplay.hasMoreResults();
|
||||||
|
|
||||||
provider.getResultMetas(results, Lang.bind(this, function(metas) {
|
provider.getResultMetas(results, Lang.bind(this, function(metas) {
|
||||||
this._clearDisplayForProvider(provider);
|
this._clearDisplayForProvider(provider);
|
||||||
meta.actor.show();
|
meta.actor.show();
|
||||||
@ -374,6 +587,15 @@ const SearchResults = new Lang.Class({
|
|||||||
this._defaultResult.setSelected(highlight);
|
this._defaultResult.setSelected(highlight);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_updateProviderIconCanFocus: function(resultDisplay) {
|
||||||
|
let meta = this._metaForProvider(resultDisplay.provider);
|
||||||
|
if (meta.icon)
|
||||||
|
meta.icon.actor.can_focus = true;
|
||||||
|
|
||||||
|
let others = this._metaForProvidersExcept(resultDisplay.provider);
|
||||||
|
others.forEach(function(meta) { if (meta.icon) meta.icon.actor.can_focus = false; });
|
||||||
|
},
|
||||||
|
|
||||||
navigateFocus: function(direction) {
|
navigateFocus: function(direction) {
|
||||||
let rtl = this.actor.get_text_direction() == Clutter.TextDirection.RTL;
|
let rtl = this.actor.get_text_direction() == Clutter.TextDirection.RTL;
|
||||||
if (direction == Gtk.DirectionType.TAB_BACKWARD ||
|
if (direction == Gtk.DirectionType.TAB_BACKWARD ||
|
||||||
@ -393,3 +615,65 @@ const SearchResults = new Lang.Class({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const ProviderIcon = new Lang.Class({
|
||||||
|
Name: 'ProviderIcon',
|
||||||
|
|
||||||
|
PROVIDER_ICON_SIZE: 48,
|
||||||
|
|
||||||
|
MORE_ICON_SIZE: 16,
|
||||||
|
|
||||||
|
_init: function(provider) {
|
||||||
|
this.provider = provider;
|
||||||
|
|
||||||
|
this.actor = new St.Button({ style_class: 'search-section-icon-bin',
|
||||||
|
reactive: true,
|
||||||
|
track_hover: true });
|
||||||
|
this.actor.connect('clicked', Lang.bind(this, this._onIconClicked));
|
||||||
|
|
||||||
|
this._content = new St.Widget({ layout_manager: new Clutter.BinLayout() });
|
||||||
|
this.actor.set_child(this._content);
|
||||||
|
|
||||||
|
let rtl = (this.actor.get_text_direction() == Clutter.TextDirection.RTL);
|
||||||
|
|
||||||
|
this.moreIcon = new St.Icon({ style_class: 'search-section-icon-more',
|
||||||
|
icon_size: this.MORE_ICON_SIZE,
|
||||||
|
icon_name: 'list-add-symbolic',
|
||||||
|
visible: false,
|
||||||
|
x_align: rtl ? Clutter.ActorAlign.START : Clutter.ActorAlign.END,
|
||||||
|
y_align: Clutter.ActorAlign.END,
|
||||||
|
// HACK: without these, ClutterBinLayout
|
||||||
|
// ignores alignment properties on the actor
|
||||||
|
x_expand: true,
|
||||||
|
y_expand: true });
|
||||||
|
|
||||||
|
this._iconBin = new St.Bin({ style_class: 'search-section-icon',
|
||||||
|
width: this.PROVIDER_ICON_SIZE,
|
||||||
|
height: this.PROVIDER_ICON_SIZE });
|
||||||
|
|
||||||
|
this._content.add_actor(this._iconBin);
|
||||||
|
this._content.add_actor(this.moreIcon);
|
||||||
|
|
||||||
|
this._createProviderIcon();
|
||||||
|
},
|
||||||
|
|
||||||
|
_createProviderIcon: function() {
|
||||||
|
let icon = new St.Icon({ icon_size: this.PROVIDER_ICON_SIZE });
|
||||||
|
|
||||||
|
if (this.provider.icon)
|
||||||
|
icon.gicon = this.provider.icon;
|
||||||
|
else
|
||||||
|
icon.icon_name = 'application-x-executable';
|
||||||
|
|
||||||
|
this._iconBin.set_child(icon);
|
||||||
|
},
|
||||||
|
|
||||||
|
activate: function() {
|
||||||
|
this.emit('launch-search');
|
||||||
|
},
|
||||||
|
|
||||||
|
_onIconClicked: function(actor) {
|
||||||
|
this.activate();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Signals.addSignalMethods(ProviderIcon.prototype);
|
||||||
|
@ -37,7 +37,7 @@ const _modes = {
|
|||||||
isGreeter: true,
|
isGreeter: true,
|
||||||
isPrimary: true,
|
isPrimary: true,
|
||||||
unlockDialog: imports.gdm.loginDialog.LoginDialog,
|
unlockDialog: imports.gdm.loginDialog.LoginDialog,
|
||||||
components: ['polkitAgent', 'mediaKeysManager'],
|
components: ['polkitAgent'],
|
||||||
panel: {
|
panel: {
|
||||||
left: ['logo'],
|
left: ['logo'],
|
||||||
center: ['dateMenu'],
|
center: ['dateMenu'],
|
||||||
@ -50,7 +50,7 @@ const _modes = {
|
|||||||
isLocked: true,
|
isLocked: true,
|
||||||
isGreeter: undefined,
|
isGreeter: undefined,
|
||||||
unlockDialog: undefined,
|
unlockDialog: undefined,
|
||||||
components: ['polkitAgent', 'telepathyClient', 'mediaKeysManager'],
|
components: ['polkitAgent', 'telepathyClient'],
|
||||||
panel: {
|
panel: {
|
||||||
left: ['userMenu'],
|
left: ['userMenu'],
|
||||||
center: [],
|
center: [],
|
||||||
@ -61,7 +61,7 @@ const _modes = {
|
|||||||
'unlock-dialog': {
|
'unlock-dialog': {
|
||||||
isLocked: true,
|
isLocked: true,
|
||||||
unlockDialog: undefined,
|
unlockDialog: undefined,
|
||||||
components: ['polkitAgent', 'telepathyClient', 'mediaKeysManager'],
|
components: ['polkitAgent', 'telepathyClient'],
|
||||||
panel: {
|
panel: {
|
||||||
left: ['userMenu'],
|
left: ['userMenu'],
|
||||||
center: [],
|
center: [],
|
||||||
@ -71,7 +71,7 @@ const _modes = {
|
|||||||
|
|
||||||
'initial-setup': {
|
'initial-setup': {
|
||||||
isPrimary: true,
|
isPrimary: true,
|
||||||
components: ['keyring', 'mediaKeysManager'],
|
components: ['keyring'],
|
||||||
panel: {
|
panel: {
|
||||||
left: [],
|
left: [],
|
||||||
center: ['dateMenu'],
|
center: ['dateMenu'],
|
||||||
@ -91,9 +91,8 @@ const _modes = {
|
|||||||
isLocked: false,
|
isLocked: false,
|
||||||
isPrimary: true,
|
isPrimary: true,
|
||||||
unlockDialog: imports.ui.unlockDialog.UnlockDialog,
|
unlockDialog: imports.ui.unlockDialog.UnlockDialog,
|
||||||
components: ['networkAgent', 'polkitAgent', 'telepathyClient', 'keyring',
|
components: ['networkAgent', 'polkitAgent', 'telepathyClient',
|
||||||
'recorder', 'autorunManager', 'automountManager',
|
'keyring', 'recorder', 'autorunManager', 'automountManager'],
|
||||||
'mediaKeysManager'],
|
|
||||||
panel: {
|
panel: {
|
||||||
left: ['activities', 'appMenu'],
|
left: ['activities', 'appMenu'],
|
||||||
center: ['dateMenu'],
|
center: ['dateMenu'],
|
||||||
|
@ -38,8 +38,8 @@ const ATIndicator = new Lang.Class({
|
|||||||
_init: function() {
|
_init: function() {
|
||||||
this.parent('preferences-desktop-accessibility-symbolic', _("Accessibility"));
|
this.parent('preferences-desktop-accessibility-symbolic', _("Accessibility"));
|
||||||
|
|
||||||
this._highContrast = this._buildHCItem();
|
let highContrast = this._buildHCItem();
|
||||||
this.menu.addMenuItem(this._highContrast);
|
this.menu.addMenuItem(highContrast);
|
||||||
|
|
||||||
let magnifier = this._buildItem(_("Zoom"), APPLICATIONS_SCHEMA,
|
let magnifier = this._buildItem(_("Zoom"), APPLICATIONS_SCHEMA,
|
||||||
'screen-magnifier-enabled');
|
'screen-magnifier-enabled');
|
||||||
@ -159,9 +159,5 @@ const ATIndicator = new Lang.Class({
|
|||||||
widget.setToggleState(active);
|
widget.setToggleState(active);
|
||||||
});
|
});
|
||||||
return widget;
|
return widget;
|
||||||
},
|
}
|
||||||
|
|
||||||
toggleHighContrast: function() {
|
|
||||||
this._highContrast.toggle();
|
|
||||||
},
|
|
||||||
});
|
});
|
||||||
|
@ -96,7 +96,7 @@ const Indicator = new Lang.Class({
|
|||||||
let minutes = time % 60;
|
let minutes = time % 60;
|
||||||
let hours = Math.floor(time / 60);
|
let hours = Math.floor(time / 60);
|
||||||
let timestring;
|
let timestring;
|
||||||
if (time >= 60) {
|
if (time > 60) {
|
||||||
if (minutes == 0) {
|
if (minutes == 0) {
|
||||||
timestring = ngettext("%d hour remaining", "%d hours remaining", hours).format(hours);
|
timestring = ngettext("%d hour remaining", "%d hours remaining", hours).format(hours);
|
||||||
} else {
|
} else {
|
||||||
|
@ -66,21 +66,7 @@ const VolumeMenu = new Lang.Class({
|
|||||||
this._onControlStateChanged();
|
this._onControlStateChanged();
|
||||||
},
|
},
|
||||||
|
|
||||||
toggleMute: function(quiet) {
|
scroll: function(direction) {
|
||||||
let muted = this._output.is_muted;
|
|
||||||
this._output.change_is_muted(!muted);
|
|
||||||
|
|
||||||
if (muted && !quiet)
|
|
||||||
this._notifyVolumeChange();
|
|
||||||
|
|
||||||
if (!muted)
|
|
||||||
return ['audio-volume-muted-symbolic', 0];
|
|
||||||
else
|
|
||||||
return [this._volumeToIcon(this._output.volume),
|
|
||||||
this._output.volume / this._volumeMax];
|
|
||||||
},
|
|
||||||
|
|
||||||
scroll: function(direction, quiet) {
|
|
||||||
let currentVolume = this._output.volume;
|
let currentVolume = this._output.volume;
|
||||||
|
|
||||||
if (direction == Clutter.ScrollDirection.DOWN) {
|
if (direction == Clutter.ScrollDirection.DOWN) {
|
||||||
@ -99,14 +85,7 @@ const VolumeMenu = new Lang.Class({
|
|||||||
this._output.push_volume();
|
this._output.push_volume();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!quiet)
|
|
||||||
this._notifyVolumeChange();
|
this._notifyVolumeChange();
|
||||||
|
|
||||||
if (this._output.is_muted)
|
|
||||||
return ['audio-volume-muted-symbolic', 0];
|
|
||||||
else
|
|
||||||
return [this._volumeToIcon(this._output.volume),
|
|
||||||
this._output.volume / this._volumeMax];
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_onControlStateChanged: function() {
|
_onControlStateChanged: function() {
|
||||||
@ -242,14 +221,14 @@ const Indicator = new Lang.Class({
|
|||||||
this.parent('audio-volume-muted-symbolic', _("Volume"));
|
this.parent('audio-volume-muted-symbolic', _("Volume"));
|
||||||
|
|
||||||
this._control = getMixerControl();
|
this._control = getMixerControl();
|
||||||
this.volumeMenu = new VolumeMenu(this._control);
|
this._volumeMenu = new VolumeMenu(this._control);
|
||||||
this.volumeMenu.connect('icon-changed', Lang.bind(this, function(menu, icon) {
|
this._volumeMenu.connect('icon-changed', Lang.bind(this, function(menu, icon) {
|
||||||
this._hasPulseAudio = (icon != null);
|
this._hasPulseAudio = (icon != null);
|
||||||
this.setIcon(icon);
|
this.setIcon(icon);
|
||||||
this._syncVisibility();
|
this._syncVisibility();
|
||||||
}));
|
}));
|
||||||
|
|
||||||
this.menu.addMenuItem(this.volumeMenu);
|
this.menu.addMenuItem(this._volumeMenu);
|
||||||
|
|
||||||
this.menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());
|
this.menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());
|
||||||
this.menu.addSettingsAction(_("Sound Settings"), 'gnome-sound-panel.desktop');
|
this.menu.addSettingsAction(_("Sound Settings"), 'gnome-sound-panel.desktop');
|
||||||
@ -263,6 +242,6 @@ const Indicator = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onScrollEvent: function(actor, event) {
|
_onScrollEvent: function(actor, event) {
|
||||||
this.volumeMenu.scroll(event.get_scroll_direction(), false);
|
this._volumeMenu.scroll(event.get_scroll_direction());
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
|
@ -151,9 +151,6 @@ const UnlockDialog = new Lang.Class({
|
|||||||
ShellEntry.addContextMenu(this._promptEntry, { isPassword: true });
|
ShellEntry.addContextMenu(this._promptEntry, { isPassword: true });
|
||||||
this.setInitialKeyFocus(this._promptEntry);
|
this.setInitialKeyFocus(this._promptEntry);
|
||||||
this._promptEntry.clutter_text.connect('activate', Lang.bind(this, this._doUnlock));
|
this._promptEntry.clutter_text.connect('activate', Lang.bind(this, this._doUnlock));
|
||||||
this._promptEntry.clutter_text.connect('text-changed', Lang.bind(this, function() {
|
|
||||||
this._updateOkButtonSensitivity(this._promptEntry.text.length > 0);
|
|
||||||
}));
|
|
||||||
|
|
||||||
this._promptLayout.add(this._promptEntry,
|
this._promptLayout.add(this._promptEntry,
|
||||||
{ expand: true,
|
{ expand: true,
|
||||||
@ -206,10 +203,6 @@ const UnlockDialog = new Lang.Class({
|
|||||||
_updateSensitivity: function(sensitive) {
|
_updateSensitivity: function(sensitive) {
|
||||||
this._promptEntry.reactive = sensitive;
|
this._promptEntry.reactive = sensitive;
|
||||||
this._promptEntry.clutter_text.editable = sensitive;
|
this._promptEntry.clutter_text.editable = sensitive;
|
||||||
this._updateOkButtonSensitivity(sensitive && this._promptEntry.text.length > 0);
|
|
||||||
},
|
|
||||||
|
|
||||||
_updateOkButtonSensitivity: function(sensitive) {
|
|
||||||
this._okButton.button.reactive = sensitive;
|
this._okButton.button.reactive = sensitive;
|
||||||
this._okButton.button.can_focus = sensitive;
|
this._okButton.button.can_focus = sensitive;
|
||||||
},
|
},
|
||||||
|
@ -572,7 +572,6 @@ const UserMenuButton = new Lang.Class({
|
|||||||
|
|
||||||
this._updateHaveShutdown();
|
this._updateHaveShutdown();
|
||||||
this._updateHaveSuspend();
|
this._updateHaveSuspend();
|
||||||
this._updateHaveHibernate();
|
|
||||||
}));
|
}));
|
||||||
this._lockdownSettings.connect('changed::' + DISABLE_LOG_OUT_KEY,
|
this._lockdownSettings.connect('changed::' + DISABLE_LOG_OUT_KEY,
|
||||||
Lang.bind(this, this._updateHaveShutdown));
|
Lang.bind(this, this._updateHaveShutdown));
|
||||||
@ -656,13 +655,6 @@ const UserMenuButton = new Lang.Class({
|
|||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
|
|
||||||
_updateHaveHibernate: function() {
|
|
||||||
this._loginManager.canHibernate(Lang.bind(this,
|
|
||||||
function(result) {
|
|
||||||
this._haveHibernate = result;
|
|
||||||
}));
|
|
||||||
},
|
|
||||||
|
|
||||||
_updateSuspendOrPowerOff: function() {
|
_updateSuspendOrPowerOff: function() {
|
||||||
if (!this._suspendOrPowerOffItem)
|
if (!this._suspendOrPowerOffItem)
|
||||||
return;
|
return;
|
||||||
@ -760,7 +752,7 @@ const UserMenuButton = new Lang.Class({
|
|||||||
item = new PopupMenu.PopupSeparatorMenuItem();
|
item = new PopupMenu.PopupSeparatorMenuItem();
|
||||||
this.menu.addMenuItem(item);
|
this.menu.addMenuItem(item);
|
||||||
|
|
||||||
item = new PopupMenu.PopupMenuItem(_("Settings"));
|
item = new PopupMenu.PopupMenuItem(_("System Settings"));
|
||||||
item.connect('activate', Lang.bind(this, this._onPreferencesActivate));
|
item.connect('activate', Lang.bind(this, this._onPreferencesActivate));
|
||||||
this.menu.addMenuItem(item);
|
this.menu.addMenuItem(item);
|
||||||
this._systemSettings = item;
|
this._systemSettings = item;
|
||||||
@ -774,7 +766,7 @@ const UserMenuButton = new Lang.Class({
|
|||||||
this._loginScreenItem = item;
|
this._loginScreenItem = item;
|
||||||
|
|
||||||
item = new PopupMenu.PopupMenuItem(_("Log Out"));
|
item = new PopupMenu.PopupMenuItem(_("Log Out"));
|
||||||
item.connect('activate', Lang.bind(this, this.logOut));
|
item.connect('activate', Lang.bind(this, this._onQuitSessionActivate));
|
||||||
this.menu.addMenuItem(item);
|
this.menu.addMenuItem(item);
|
||||||
this._logoutItem = item;
|
this._logoutItem = item;
|
||||||
|
|
||||||
@ -843,7 +835,7 @@ const UserMenuButton = new Lang.Class({
|
|||||||
Gdm.goto_login_session_sync(null);
|
Gdm.goto_login_session_sync(null);
|
||||||
},
|
},
|
||||||
|
|
||||||
logOut: function() {
|
_onQuitSessionActivate: function() {
|
||||||
Main.overview.hide();
|
Main.overview.hide();
|
||||||
this._session.LogoutRemote(0);
|
this._session.LogoutRemote(0);
|
||||||
},
|
},
|
||||||
@ -855,60 +847,25 @@ const UserMenuButton = new Lang.Class({
|
|||||||
this._session.RebootRemote();
|
this._session.RebootRemote();
|
||||||
},
|
},
|
||||||
|
|
||||||
shutdown: function() {
|
|
||||||
this._session.ShutdownRemote();
|
|
||||||
},
|
|
||||||
|
|
||||||
suspend: function() {
|
|
||||||
if (!this._haveSuspend)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
// Ensure we only suspend after locking the screen
|
|
||||||
if (this._screenSaverSettings.get_boolean(LOCK_ENABLED_KEY)) {
|
|
||||||
let tmpId = Main.screenShield.connect('lock-screen-shown', Lang.bind(this, function() {
|
|
||||||
Main.screenShield.disconnect(tmpId);
|
|
||||||
|
|
||||||
this._loginManager.suspend();
|
|
||||||
}));
|
|
||||||
|
|
||||||
this.menu.close(BoxPointer.PopupAnimation.NONE);
|
|
||||||
Main.screenShield.lock(true);
|
|
||||||
} else {
|
|
||||||
this._loginManager.suspend();
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
hibernate: function() {
|
|
||||||
if (!this._haveHibernate)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
// Ensure we only suspend after locking the screen
|
|
||||||
if (this._screenSaverSettings.get_boolean(LOCK_ENABLED_KEY)) {
|
|
||||||
let tmpId = Main.screenShield.connect('lock-screen-shown', Lang.bind(this, function() {
|
|
||||||
Main.screenShield.disconnect(tmpId);
|
|
||||||
|
|
||||||
this._loginManager.hibernate();
|
|
||||||
}));
|
|
||||||
|
|
||||||
this.menu.close(BoxPointer.PopupAnimation.NONE);
|
|
||||||
Main.screenShield.lock(true);
|
|
||||||
} else {
|
|
||||||
this._loginManager.hibernate();
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
|
|
||||||
_onSuspendOrPowerOffActivate: function() {
|
_onSuspendOrPowerOffActivate: function() {
|
||||||
Main.overview.hide();
|
Main.overview.hide();
|
||||||
|
|
||||||
if (this._haveShutdown &&
|
if (this._haveShutdown &&
|
||||||
this._suspendOrPowerOffItem.state == PopupMenu.PopupAlternatingMenuItemState.DEFAULT) {
|
this._suspendOrPowerOffItem.state == PopupMenu.PopupAlternatingMenuItemState.DEFAULT) {
|
||||||
this.shutdown();
|
this._session.ShutdownRemote();
|
||||||
} else {
|
} else {
|
||||||
this.suspend();
|
if (this._screenSaverSettings.get_boolean(LOCK_ENABLED_KEY)) {
|
||||||
|
let tmpId = Main.screenShield.connect('lock-screen-shown', Lang.bind(this, function() {
|
||||||
|
Main.screenShield.disconnect(tmpId);
|
||||||
|
|
||||||
|
this._loginManager.suspend();
|
||||||
|
}));
|
||||||
|
|
||||||
|
this.menu.close(BoxPointer.PopupAnimation.NONE);
|
||||||
|
Main.screenShield.lock(true);
|
||||||
|
} else {
|
||||||
|
this._loginManager.suspend();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -52,7 +52,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
|
|
||||||
this._activePage = null;
|
this._activePage = null;
|
||||||
|
|
||||||
this.active = false;
|
this.entryNonEmpty = false;
|
||||||
this._searchPending = false;
|
this._searchPending = false;
|
||||||
this._searchTimeoutId = 0;
|
this._searchTimeoutId = 0;
|
||||||
|
|
||||||
@ -90,7 +90,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
this._appsPage = this._addPage(this._appDisplay.actor, null,
|
this._appsPage = this._addPage(this._appDisplay.actor, null,
|
||||||
_("Applications"), 'system-run-symbolic');
|
_("Applications"), 'system-run-symbolic');
|
||||||
|
|
||||||
this._searchResults = new SearchDisplay.SearchResults(this._searchSystem);
|
this._searchResults = new SearchDisplay.SearchDisplay(this._searchSystem);
|
||||||
this._searchPage = this._addPage(this._searchResults.actor, this._entry,
|
this._searchPage = this._addPage(this._searchResults.actor, this._entry,
|
||||||
_("Search"), 'edit-find-symbolic');
|
_("Search"), 'edit-find-symbolic');
|
||||||
|
|
||||||
@ -114,9 +114,6 @@ const ViewSelector = new Lang.Class({
|
|||||||
|
|
||||||
global.focus_manager.add_group(this._searchResults.actor);
|
global.focus_manager.add_group(this._searchResults.actor);
|
||||||
|
|
||||||
Main.overview.connect('item-drag-begin',
|
|
||||||
Lang.bind(this, this._resetShowAppsButton));
|
|
||||||
|
|
||||||
this._stageKeyPressId = 0;
|
this._stageKeyPressId = 0;
|
||||||
Main.overview.connect('showing', Lang.bind(this,
|
Main.overview.connect('showing', Lang.bind(this,
|
||||||
function () {
|
function () {
|
||||||
@ -133,17 +130,6 @@ const ViewSelector = new Lang.Class({
|
|||||||
}
|
}
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// Public constraints which may be used to tie actors' height or
|
|
||||||
// vertical position to the current tab's content; as the content's
|
|
||||||
// height and position depend on the view selector's style properties
|
|
||||||
// (e.g. font size, padding, spacing, ...) it would be extremely hard
|
|
||||||
// and ugly to get these from the outside. While it would be possible
|
|
||||||
// to use position and height properties directly, outside code would
|
|
||||||
// need to ensure that the content is properly allocated before
|
|
||||||
// accessing the properties.
|
|
||||||
this.constrainHeight = new Clutter.BindConstraint({ source: this._pageArea,
|
|
||||||
coordinate: Clutter.BindCoordinate.HEIGHT });
|
|
||||||
|
|
||||||
global.display.add_keybinding('toggle-application-view',
|
global.display.add_keybinding('toggle-application-view',
|
||||||
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
||||||
Meta.KeyBindingFlags.NONE,
|
Meta.KeyBindingFlags.NONE,
|
||||||
@ -196,7 +182,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
})
|
})
|
||||||
});;
|
});;
|
||||||
this._pageArea.add_actor(page);
|
this._pageArea.add_actor(page);
|
||||||
return page;
|
return page
|
||||||
},
|
},
|
||||||
|
|
||||||
_showPage: function(page) {
|
_showPage: function(page) {
|
||||||
@ -230,7 +216,9 @@ const ViewSelector = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onShowAppsButtonToggled: function() {
|
_onShowAppsButtonToggled: function() {
|
||||||
if (this.active)
|
this.emit('apps-button-checked', this._showAppsButton.checked);
|
||||||
|
|
||||||
|
if (this.entryNonEmpty)
|
||||||
this.reset();
|
this.reset();
|
||||||
else
|
else
|
||||||
this._showPage(this._showAppsButton.checked ? this._appsPage
|
this._showPage(this._showAppsButton.checked ? this._appsPage
|
||||||
@ -246,7 +234,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
let symbol = event.get_key_symbol();
|
let symbol = event.get_key_symbol();
|
||||||
|
|
||||||
if (symbol == Clutter.Escape) {
|
if (symbol == Clutter.Escape) {
|
||||||
if (this.active)
|
if (this.entryNonEmpty)
|
||||||
this.reset();
|
this.reset();
|
||||||
else if (this._showAppsButton.checked)
|
else if (this._showAppsButton.checked)
|
||||||
this._resetShowAppsButton();
|
this._resetShowAppsButton();
|
||||||
@ -254,9 +242,9 @@ const ViewSelector = new Lang.Class({
|
|||||||
Main.overview.hide();
|
Main.overview.hide();
|
||||||
return true;
|
return true;
|
||||||
} else if (Clutter.keysym_to_unicode(symbol) ||
|
} else if (Clutter.keysym_to_unicode(symbol) ||
|
||||||
(symbol == Clutter.BackSpace && this.active)) {
|
(symbol == Clutter.BackSpace && this.entryNonEmpty)) {
|
||||||
this.startSearch(event);
|
this.startSearch(event);
|
||||||
} else if (!this.active) {
|
} else if (!this.entryNonEmpty) {
|
||||||
if (symbol == Clutter.Tab || symbol == Clutter.Down) {
|
if (symbol == Clutter.Tab || symbol == Clutter.Down) {
|
||||||
this._activePage.navigate_focus(null, Gtk.DirectionType.TAB_FORWARD, false);
|
this._activePage.navigate_focus(null, Gtk.DirectionType.TAB_FORWARD, false);
|
||||||
return true;
|
return true;
|
||||||
@ -269,6 +257,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_searchCancelled: function() {
|
_searchCancelled: function() {
|
||||||
|
this.emit('search-cancelled');
|
||||||
this._showPage(this._showAppsButton.checked ? this._appsPage
|
this._showPage(this._showAppsButton.checked ? this._appsPage
|
||||||
: this._workspacesPage);
|
: this._workspacesPage);
|
||||||
|
|
||||||
@ -330,13 +319,14 @@ const ViewSelector = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onTextChanged: function (se, prop) {
|
_onTextChanged: function (se, prop) {
|
||||||
let searchPreviouslyActive = this.active;
|
let searchPreviouslyActive = this.entryNonEmpty;
|
||||||
this.active = this._entry.get_text() != '';
|
this.entryNonEmpty = this._entry.get_text() != '';
|
||||||
this._searchPending = this.active && !searchPreviouslyActive;
|
this._searchPending = this.entryNonEmpty && !searchPreviouslyActive;
|
||||||
if (this._searchPending) {
|
if (this._searchPending) {
|
||||||
this._searchResults.startingSearch();
|
this._searchResults.startingSearch();
|
||||||
}
|
}
|
||||||
if (this.active) {
|
if (this.entryNonEmpty) {
|
||||||
|
this.emit('search-begin');
|
||||||
this._entry.set_secondary_icon(this._activeIcon);
|
this._entry.set_secondary_icon(this._activeIcon);
|
||||||
|
|
||||||
if (this._iconClickedId == 0) {
|
if (this._iconClickedId == 0) {
|
||||||
@ -353,7 +343,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
this._entry.set_secondary_icon(this._inactiveIcon);
|
this._entry.set_secondary_icon(this._inactiveIcon);
|
||||||
this._searchCancelled();
|
this._searchCancelled();
|
||||||
}
|
}
|
||||||
if (!this.active) {
|
if (!this.entryNonEmpty) {
|
||||||
if (this._searchTimeoutId > 0) {
|
if (this._searchTimeoutId > 0) {
|
||||||
Mainloop.source_remove(this._searchTimeoutId);
|
Mainloop.source_remove(this._searchTimeoutId);
|
||||||
this._searchTimeoutId = 0;
|
this._searchTimeoutId = 0;
|
||||||
@ -381,7 +371,7 @@ const ViewSelector = new Lang.Class({
|
|||||||
}
|
}
|
||||||
this._searchResults.activateDefault();
|
this._searchResults.activateDefault();
|
||||||
return true;
|
return true;
|
||||||
} else if (this.active) {
|
} else if (this.entryNonEmpty) {
|
||||||
let arrowNext, nextDirection;
|
let arrowNext, nextDirection;
|
||||||
if (entry.get_text_direction() == Clutter.TextDirection.RTL) {
|
if (entry.get_text_direction() == Clutter.TextDirection.RTL) {
|
||||||
arrowNext = Clutter.Left;
|
arrowNext = Clutter.Left;
|
||||||
|
@ -39,8 +39,6 @@ const WindowAttentionHandler = new Lang.Class({
|
|||||||
let [title, banner] = this._getTitleAndBanner(app, window);
|
let [title, banner] = this._getTitleAndBanner(app, window);
|
||||||
|
|
||||||
let notification = new MessageTray.Notification(source, title, banner);
|
let notification = new MessageTray.Notification(source, title, banner);
|
||||||
notification.setForFeedback(true);
|
|
||||||
|
|
||||||
source.notify(notification);
|
source.notify(notification);
|
||||||
|
|
||||||
source.signalIDs.push(window.connect('notify::title', Lang.bind(this, function() {
|
source.signalIDs.push(window.connect('notify::title', Lang.bind(this, function() {
|
||||||
|
@ -12,7 +12,6 @@ const AltTab = imports.ui.altTab;
|
|||||||
const WorkspaceSwitcherPopup = imports.ui.workspaceSwitcherPopup;
|
const WorkspaceSwitcherPopup = imports.ui.workspaceSwitcherPopup;
|
||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const Util = imports.misc.util;
|
|
||||||
|
|
||||||
const SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
const SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
||||||
const WINDOW_ANIMATION_TIME = 0.25;
|
const WINDOW_ANIMATION_TIME = 0.25;
|
||||||
@ -102,32 +101,32 @@ const WindowManager = new Lang.Class({
|
|||||||
this._shellwm.connect('destroy', Lang.bind(this, this._destroyWindow));
|
this._shellwm.connect('destroy', Lang.bind(this, this._destroyWindow));
|
||||||
|
|
||||||
this._workspaceSwitcherPopup = null;
|
this._workspaceSwitcherPopup = null;
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-to-workspace-left',
|
Meta.keybindings_set_custom_handler('switch-to-workspace-left',
|
||||||
Util.wrapKeybinding(Lang.bind(this, this._showWorkspaceSwitcher), true));
|
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-to-workspace-right',
|
|
||||||
Util.wrapKeybinding(Lang.bind(this, this._showWorkspaceSwitcher), true));
|
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-to-workspace-up',
|
|
||||||
Util.wrapKeybinding(Lang.bind(this, this._showWorkspaceSwitcher), true));
|
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-to-workspace-down',
|
|
||||||
Util.wrapKeybinding(Lang.bind(this, this._showWorkspaceSwitcher), true));
|
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-move-to-workspace-left',
|
|
||||||
Lang.bind(this, this._showWorkspaceSwitcher));
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-move-to-workspace-right',
|
Meta.keybindings_set_custom_handler('switch-to-workspace-right',
|
||||||
Lang.bind(this, this._showWorkspaceSwitcher));
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-move-to-workspace-up',
|
Meta.keybindings_set_custom_handler('switch-to-workspace-up',
|
||||||
Lang.bind(this, this._showWorkspaceSwitcher));
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-move-to-workspace-down',
|
Meta.keybindings_set_custom_handler('switch-to-workspace-down',
|
||||||
Lang.bind(this, this._showWorkspaceSwitcher));
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-windows',
|
Meta.keybindings_set_custom_handler('move-to-workspace-left',
|
||||||
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
|
Meta.keybindings_set_custom_handler('move-to-workspace-right',
|
||||||
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
|
Meta.keybindings_set_custom_handler('move-to-workspace-up',
|
||||||
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
|
Meta.keybindings_set_custom_handler('move-to-workspace-down',
|
||||||
|
Lang.bind(this, this._showWorkspaceSwitcher));
|
||||||
|
Meta.keybindings_set_custom_handler('switch-windows',
|
||||||
Lang.bind(this, this._startAppSwitcher));
|
Lang.bind(this, this._startAppSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-group',
|
Meta.keybindings_set_custom_handler('switch-group',
|
||||||
Lang.bind(this, this._startAppSwitcher));
|
Lang.bind(this, this._startAppSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-windows-backward',
|
Meta.keybindings_set_custom_handler('switch-windows-backward',
|
||||||
Lang.bind(this, this._startAppSwitcher));
|
Lang.bind(this, this._startAppSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-group-backward',
|
Meta.keybindings_set_custom_handler('switch-group-backward',
|
||||||
Lang.bind(this, this._startAppSwitcher));
|
Lang.bind(this, this._startAppSwitcher));
|
||||||
Meta.keybindings_set_custom_handler('internal-keybinding-switch-panels',
|
Meta.keybindings_set_custom_handler('switch-panels',
|
||||||
Util.wrapKeybinding(Lang.bind(this, this._startA11ySwitcher), true));
|
Lang.bind(this, this._startA11ySwitcher));
|
||||||
global.display.add_keybinding('open-application-menu',
|
global.display.add_keybinding('open-application-menu',
|
||||||
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
new Gio.Settings({ schema: SHELL_KEYBINDINGS_SCHEMA }),
|
||||||
Meta.KeyBindingFlags.NONE,
|
Meta.KeyBindingFlags.NONE,
|
||||||
@ -553,32 +552,30 @@ const WindowManager = new Lang.Class({
|
|||||||
let backwards = modifiers & Meta.VirtualModifier.SHIFT_MASK;
|
let backwards = modifiers & Meta.VirtualModifier.SHIFT_MASK;
|
||||||
if (!tabPopup.show(backwards, binding.get_name(), binding.get_mask()))
|
if (!tabPopup.show(backwards, binding.get_name(), binding.get_mask()))
|
||||||
tabPopup.destroy();
|
tabPopup.destroy();
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_startA11ySwitcher : function(display, screen, window, binding) {
|
_startA11ySwitcher : function(display, screen, window, binding) {
|
||||||
let modifiers = binding.get_modifiers();
|
let modifiers = binding.get_modifiers();
|
||||||
let backwards = modifiers & Meta.VirtualModifier.SHIFT_MASK;
|
let backwards = modifiers & Meta.VirtualModifier.SHIFT_MASK;
|
||||||
Main.ctrlAltTabManager.popup(backwards, binding.get_mask());
|
Main.ctrlAltTabManager.popup(backwards, binding.get_mask());
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_openAppMenu : function(display, screen, window, event, binding) {
|
_openAppMenu : function(display, screen, window, event, binding) {
|
||||||
Main.panel.openAppMenu();
|
Main.panel.openAppMenu();
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_showWorkspaceSwitcher : function(display, screen, window, binding) {
|
_showWorkspaceSwitcher : function(display, screen, window, binding) {
|
||||||
if (screen.n_workspaces == 1)
|
if (screen.n_workspaces == 1)
|
||||||
return false;
|
return;
|
||||||
|
|
||||||
let [,,action,,,direction] = binding.get_name().split('-');
|
let [action,,,direction] = binding.get_name().split('-');
|
||||||
let direction = Meta.MotionDirection[direction.toUpperCase()];
|
let direction = Meta.MotionDirection[direction.toUpperCase()];
|
||||||
let newWs;
|
let newWs;
|
||||||
|
|
||||||
|
|
||||||
if (direction != Meta.MotionDirection.UP &&
|
if (direction != Meta.MotionDirection.UP &&
|
||||||
direction != Meta.MotionDirection.DOWN)
|
direction != Meta.MotionDirection.DOWN)
|
||||||
return false;
|
return;
|
||||||
|
|
||||||
if (action == 'switch')
|
if (action == 'switch')
|
||||||
newWs = this.actionMoveWorkspace(direction);
|
newWs = this.actionMoveWorkspace(direction);
|
||||||
@ -594,8 +591,6 @@ const WindowManager = new Lang.Class({
|
|||||||
}
|
}
|
||||||
this._workspaceSwitcherPopup.display(direction, newWs.index());
|
this._workspaceSwitcherPopup.display(direction, newWs.index());
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
actionMoveWorkspace: function(direction) {
|
actionMoveWorkspace: function(direction) {
|
||||||
|
@ -1073,6 +1073,9 @@ const Workspace = new Lang.Class({
|
|||||||
* ANIMATE - Indicates that we need animate changing position.
|
* ANIMATE - Indicates that we need animate changing position.
|
||||||
*/
|
*/
|
||||||
positionWindows: function(flags) {
|
positionWindows: function(flags) {
|
||||||
|
if (this.leavingOverview)
|
||||||
|
return;
|
||||||
|
|
||||||
this._positionWindowsFlags |= flags;
|
this._positionWindowsFlags |= flags;
|
||||||
|
|
||||||
if (this._positionWindowsId > 0)
|
if (this._positionWindowsId > 0)
|
||||||
|
@ -493,6 +493,7 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
_init: function() {
|
_init: function() {
|
||||||
this.actor = new Shell.GenericContainer({ reactive: true,
|
this.actor = new Shell.GenericContainer({ reactive: true,
|
||||||
style_class: 'workspace-thumbnails',
|
style_class: 'workspace-thumbnails',
|
||||||
|
can_focus: true,
|
||||||
request_mode: Clutter.RequestMode.WIDTH_FOR_HEIGHT });
|
request_mode: Clutter.RequestMode.WIDTH_FOR_HEIGHT });
|
||||||
this.actor.connect('get-preferred-width', Lang.bind(this, this._getPreferredWidth));
|
this.actor.connect('get-preferred-width', Lang.bind(this, this._getPreferredWidth));
|
||||||
this.actor.connect('get-preferred-height', Lang.bind(this, this._getPreferredHeight));
|
this.actor.connect('get-preferred-height', Lang.bind(this, this._getPreferredHeight));
|
||||||
@ -526,6 +527,8 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
this._dropPlaceholder = new St.Bin({ style_class: 'placeholder' });
|
this._dropPlaceholder = new St.Bin({ style_class: 'placeholder' });
|
||||||
this.actor.add_actor(this._dropPlaceholder);
|
this.actor.add_actor(this._dropPlaceholder);
|
||||||
|
|
||||||
|
this.visible = true;
|
||||||
|
|
||||||
this._targetScale = 0;
|
this._targetScale = 0;
|
||||||
this._scale = 0;
|
this._scale = 0;
|
||||||
this._pendingScaleUpdate = false;
|
this._pendingScaleUpdate = false;
|
||||||
@ -541,12 +544,21 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
|
|
||||||
this.actor.connect('button-press-event', function() { return true; });
|
this.actor.connect('button-press-event', function() { return true; });
|
||||||
this.actor.connect('button-release-event', Lang.bind(this, this._onButtonRelease));
|
this.actor.connect('button-release-event', Lang.bind(this, this._onButtonRelease));
|
||||||
|
this.actor.connect('scroll-event',
|
||||||
|
Lang.bind(this, this._onScrollEvent));
|
||||||
|
this.actor.connect('key-release-event',
|
||||||
|
Lang.bind(this, this._onKeyRelease));
|
||||||
|
|
||||||
Main.overview.connect('item-drag-begin',
|
Main.overview.connect('showing',
|
||||||
|
Lang.bind(this, this._createThumbnails));
|
||||||
|
Main.overview.connect('hidden',
|
||||||
|
Lang.bind(this, this._destroyThumbnails));
|
||||||
|
|
||||||
|
Main.overview.connect('app-drag-begin',
|
||||||
Lang.bind(this, this._onDragBegin));
|
Lang.bind(this, this._onDragBegin));
|
||||||
Main.overview.connect('item-drag-end',
|
Main.overview.connect('app-drag-end',
|
||||||
Lang.bind(this, this._onDragEnd));
|
Lang.bind(this, this._onDragEnd));
|
||||||
Main.overview.connect('item-drag-cancelled',
|
Main.overview.connect('app-drag-cancelled',
|
||||||
Lang.bind(this, this._onDragCancelled));
|
Lang.bind(this, this._onDragCancelled));
|
||||||
Main.overview.connect('window-drag-begin',
|
Main.overview.connect('window-drag-begin',
|
||||||
Lang.bind(this, this._onDragBegin));
|
Lang.bind(this, this._onDragBegin));
|
||||||
@ -719,10 +731,16 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
show: function() {
|
_createThumbnails: function() {
|
||||||
this._switchWorkspaceNotifyId =
|
this._switchWorkspaceNotifyId =
|
||||||
global.window_manager.connect('switch-workspace',
|
global.window_manager.connect('switch-workspace',
|
||||||
Lang.bind(this, this._activeWorkspaceChanged));
|
Lang.bind(this, this._activeWorkspaceChanged));
|
||||||
|
this._nWorkspacesNotifyId =
|
||||||
|
global.screen.connect('notify::n-workspaces',
|
||||||
|
Lang.bind(this, this._workspacesChanged));
|
||||||
|
this._syncStackingId =
|
||||||
|
Main.overview.connect('sync-window-stacking',
|
||||||
|
Lang.bind(this, this.syncStacking));
|
||||||
|
|
||||||
this._targetScale = 0;
|
this._targetScale = 0;
|
||||||
this._scale = 0;
|
this._scale = 0;
|
||||||
@ -746,17 +764,86 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
this.addThumbnails(0, global.screen.n_workspaces);
|
this.addThumbnails(0, global.screen.n_workspaces);
|
||||||
},
|
},
|
||||||
|
|
||||||
hide: function() {
|
_destroyThumbnails: function() {
|
||||||
if (this._switchWorkspaceNotifyId > 0) {
|
if (this._switchWorkspaceNotifyId > 0) {
|
||||||
global.window_manager.disconnect(this._switchWorkspaceNotifyId);
|
global.window_manager.disconnect(this._switchWorkspaceNotifyId);
|
||||||
this._switchWorkspaceNotifyId = 0;
|
this._switchWorkspaceNotifyId = 0;
|
||||||
}
|
}
|
||||||
|
if (this._nWorkspacesNotifyId > 0) {
|
||||||
|
global.screen.disconnect(this._nWorkspacesNotifyId);
|
||||||
|
this._nWorkspacesNotifyId = 0;
|
||||||
|
}
|
||||||
|
if (this._syncStackingId > 0) {
|
||||||
|
Main.overview.disconnect(this._syncStackingId);
|
||||||
|
this._syncStackingId = 0;
|
||||||
|
}
|
||||||
|
|
||||||
for (let w = 0; w < this._thumbnails.length; w++)
|
for (let w = 0; w < this._thumbnails.length; w++)
|
||||||
this._thumbnails[w].destroy();
|
this._thumbnails[w].destroy();
|
||||||
this._thumbnails = [];
|
this._thumbnails = [];
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_computeThumbnailsX: function() {
|
||||||
|
this._targetX = this.actor.get_x();
|
||||||
|
|
||||||
|
let rtl = (this.actor.get_text_direction() == Clutter.TextDirection.RTL);
|
||||||
|
|
||||||
|
if (rtl)
|
||||||
|
this._hiddenX = -this.actor.width;
|
||||||
|
else
|
||||||
|
this._hiddenX = this._targetX + this.actor.width;
|
||||||
|
},
|
||||||
|
|
||||||
|
show: function() {
|
||||||
|
if (this.visible)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this.visible = true;
|
||||||
|
|
||||||
|
this.actor.show();
|
||||||
|
Tweener.addTween(this.actor, { translation_x: this._targetX,
|
||||||
|
transition: 'easeOutQuad',
|
||||||
|
time: SLIDE_ANIMATION_TIME
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
hide: function() {
|
||||||
|
if (!this.visible)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this.visible = false;
|
||||||
|
|
||||||
|
Tweener.addTween(this.actor, { translation_x: this._hiddenX,
|
||||||
|
transition: 'easeOutQuad',
|
||||||
|
time: SLIDE_ANIMATION_TIME,
|
||||||
|
onComplete: Lang.bind(this, function () {
|
||||||
|
this.actor.hide();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
_workspacesChanged: function() {
|
||||||
|
let oldNumWorkspaces = this._thumbnails.length;
|
||||||
|
let newNumWorkspaces = global.screen.n_workspaces;
|
||||||
|
let active = global.screen.get_active_workspace_index();
|
||||||
|
|
||||||
|
if (newNumWorkspaces > oldNumWorkspaces) {
|
||||||
|
this.addThumbnails(oldNumWorkspaces, newNumWorkspaces - oldNumWorkspaces);
|
||||||
|
} else {
|
||||||
|
let removedIndex;
|
||||||
|
let removedNum = oldNumWorkspaces - newNumWorkspaces;
|
||||||
|
for (let w = 0; w < oldNumWorkspaces; w++) {
|
||||||
|
let metaWorkspace = global.screen.get_workspace_by_index(w);
|
||||||
|
if (this._thumbnails[w].metaWorkspace != metaWorkspace) {
|
||||||
|
removedIndex = w;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
this.removeThumbnails(removedIndex, removedNum);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
addThumbnails: function(start, count) {
|
addThumbnails: function(start, count) {
|
||||||
for (let k = start; k < start + count; k++) {
|
for (let k = start; k < start + count; k++) {
|
||||||
let metaWorkspace = global.screen.get_workspace_by_index(k);
|
let metaWorkspace = global.screen.get_workspace_by_index(k);
|
||||||
@ -802,7 +889,7 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
this._queueUpdateStates();
|
this._queueUpdateStates();
|
||||||
},
|
},
|
||||||
|
|
||||||
syncStacking: function(stackIndices) {
|
syncStacking: function(actor, stackIndices) {
|
||||||
for (let i = 0; i < this._thumbnails.length; i++)
|
for (let i = 0; i < this._thumbnails.length; i++)
|
||||||
this._thumbnails[i].syncStacking(stackIndices);
|
this._thumbnails[i].syncStacking(stackIndices);
|
||||||
},
|
},
|
||||||
@ -924,6 +1011,8 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
this._computeThumbnailsX();
|
||||||
},
|
},
|
||||||
|
|
||||||
_queueUpdateStates: function() {
|
_queueUpdateStates: function() {
|
||||||
@ -1157,5 +1246,30 @@ const ThumbnailsBox = new Lang.Class({
|
|||||||
},
|
},
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
});
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
_onScrollEvent: function (actor, event) {
|
||||||
|
switch (event.get_scroll_direction()) {
|
||||||
|
case Clutter.ScrollDirection.UP:
|
||||||
|
Main.wm.actionMoveWorkspace(Meta.MotionDirection.UP);
|
||||||
|
break;
|
||||||
|
case Clutter.ScrollDirection.DOWN:
|
||||||
|
Main.wm.actionMoveWorkspace(Meta.MotionDirection.DOWN);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
_onKeyRelease: function (actor, event) {
|
||||||
|
switch (event.get_key_symbol()) {
|
||||||
|
case Clutter.KEY_Up:
|
||||||
|
Main.wm.actionMoveWorkspace(Meta.MotionDirection.UP);
|
||||||
|
break;
|
||||||
|
case Clutter.KEY_Down:
|
||||||
|
Main.wm.actionMoveWorkspace(Meta.MotionDirection.DOWN);
|
||||||
|
break;
|
||||||
|
case Clutter.KEY_Return:
|
||||||
|
Main.overview.toggle();
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -22,8 +22,6 @@ const MAX_WORKSPACES = 16;
|
|||||||
|
|
||||||
const OVERRIDE_SCHEMA = 'org.gnome.shell.overrides';
|
const OVERRIDE_SCHEMA = 'org.gnome.shell.overrides';
|
||||||
|
|
||||||
const CONTROLS_POP_IN_TIME = 0.1;
|
|
||||||
|
|
||||||
|
|
||||||
const WorkspacesView = new Lang.Class({
|
const WorkspacesView = new Lang.Class({
|
||||||
Name: 'WorkspacesView',
|
Name: 'WorkspacesView',
|
||||||
@ -106,9 +104,9 @@ const WorkspacesView = new Lang.Class({
|
|||||||
global.window_manager.connect('switch-workspace',
|
global.window_manager.connect('switch-workspace',
|
||||||
Lang.bind(this, this._activeWorkspaceChanged));
|
Lang.bind(this, this._activeWorkspaceChanged));
|
||||||
|
|
||||||
this._itemDragBeginId = Main.overview.connect('item-drag-begin',
|
this._appDragBeginId = Main.overview.connect('app-drag-begin',
|
||||||
Lang.bind(this, this._dragBegin));
|
Lang.bind(this, this._dragBegin));
|
||||||
this._itemDragEndId = Main.overview.connect('item-drag-end',
|
this._appDragEndId = Main.overview.connect('app-drag-end',
|
||||||
Lang.bind(this, this._dragEnd));
|
Lang.bind(this, this._dragEnd));
|
||||||
this._windowDragBeginId = Main.overview.connect('window-drag-begin',
|
this._windowDragBeginId = Main.overview.connect('window-drag-begin',
|
||||||
Lang.bind(this, this._dragBegin));
|
Lang.bind(this, this._dragBegin));
|
||||||
@ -327,13 +325,13 @@ const WorkspacesView = new Lang.Class({
|
|||||||
if (this._inDrag)
|
if (this._inDrag)
|
||||||
this._dragEnd();
|
this._dragEnd();
|
||||||
|
|
||||||
if (this._itemDragBeginId > 0) {
|
if (this._appDragBeginId > 0) {
|
||||||
Main.overview.disconnect(this._itemDragBeginId);
|
Main.overview.disconnect(this._appDragBeginId);
|
||||||
this._itemDragBeginId = 0;
|
this._appDragBeginId = 0;
|
||||||
}
|
}
|
||||||
if (this._itemDragEndId > 0) {
|
if (this._appDragEndId > 0) {
|
||||||
Main.overview.disconnect(this._itemDragEndId);
|
Main.overview.disconnect(this._appDragEndId);
|
||||||
this._itemDragEndId = 0;
|
this._appDragEndId = 0;
|
||||||
}
|
}
|
||||||
if (this._windowDragBeginId > 0) {
|
if (this._windowDragBeginId > 0) {
|
||||||
Main.overview.disconnect(this._windowDragBeginId);
|
Main.overview.disconnect(this._windowDragBeginId);
|
||||||
@ -460,25 +458,8 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
this.actor.connect('parent-set', Lang.bind(this, this._parentSet));
|
this.actor.connect('parent-set', Lang.bind(this, this._parentSet));
|
||||||
this.actor.set_clip_to_allocation(true);
|
this.actor.set_clip_to_allocation(true);
|
||||||
|
|
||||||
let controls = new St.Bin({ style_class: 'workspace-controls',
|
|
||||||
request_mode: Clutter.RequestMode.WIDTH_FOR_HEIGHT,
|
|
||||||
y_align: St.Align.START,
|
|
||||||
y_fill: true });
|
|
||||||
this._controls = controls;
|
|
||||||
this.actor.add_actor(controls);
|
|
||||||
|
|
||||||
controls.reactive = true;
|
|
||||||
controls.track_hover = true;
|
|
||||||
controls.connect('notify::hover',
|
|
||||||
Lang.bind(this, this._onControlsHoverChanged));
|
|
||||||
controls.connect('scroll-event',
|
|
||||||
Lang.bind(this, this._onScrollEvent));
|
|
||||||
|
|
||||||
this._primaryIndex = Main.layoutManager.primaryIndex;
|
this._primaryIndex = Main.layoutManager.primaryIndex;
|
||||||
|
|
||||||
this._thumbnailsBox = new WorkspaceThumbnail.ThumbnailsBox();
|
|
||||||
controls.add_actor(this._thumbnailsBox.actor);
|
|
||||||
|
|
||||||
this._workspacesViews = null;
|
this._workspacesViews = null;
|
||||||
this._primaryScrollAdjustment = null;
|
this._primaryScrollAdjustment = null;
|
||||||
|
|
||||||
@ -491,34 +472,14 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
this._inDrag = false;
|
this._inDrag = false;
|
||||||
this._cancelledDrag = false;
|
this._cancelledDrag = false;
|
||||||
|
|
||||||
this._controlsInitiallyHovered = false;
|
|
||||||
this._alwaysZoomOut = false;
|
|
||||||
this._zoomOut = false;
|
|
||||||
this._zoomFraction = 0;
|
|
||||||
|
|
||||||
this._updateAlwaysZoom();
|
|
||||||
|
|
||||||
// If we stop hiding the overview on layout changes, we will need to
|
|
||||||
// update the _workspacesViews here
|
|
||||||
Main.layoutManager.connect('monitors-changed', Lang.bind(this, this._updateAlwaysZoom));
|
|
||||||
|
|
||||||
Main.xdndHandler.connect('drag-begin', Lang.bind(this, function(){
|
|
||||||
this._alwaysZoomOut = true;
|
|
||||||
}));
|
|
||||||
|
|
||||||
Main.xdndHandler.connect('drag-end', Lang.bind(this, function(){
|
|
||||||
this._alwaysZoomOut = false;
|
|
||||||
this._updateAlwaysZoom();
|
|
||||||
}));
|
|
||||||
|
|
||||||
global.screen.connect('notify::n-workspaces',
|
global.screen.connect('notify::n-workspaces',
|
||||||
Lang.bind(this, this._workspacesChanged));
|
Lang.bind(this, this._workspacesChanged));
|
||||||
|
|
||||||
this._switchWorkspaceNotifyId = 0;
|
this._switchWorkspaceNotifyId = 0;
|
||||||
|
|
||||||
this._itemDragBeginId = 0;
|
this._appDragBeginId = 0;
|
||||||
this._itemDragCancelledId = 0;
|
this._appDragCancelledId = 0;
|
||||||
this._itemDragEndId = 0;
|
this._appDragEndId = 0;
|
||||||
this._windowDragBeginId = 0;
|
this._windowDragBeginId = 0;
|
||||||
this._windowDragCancelledId = 0;
|
this._windowDragCancelledId = 0;
|
||||||
this._windowDragEndId = 0;
|
this._windowDragEndId = 0;
|
||||||
@ -538,41 +499,20 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
show: function() {
|
show: function() {
|
||||||
if(!this._alwaysZoomOut) {
|
|
||||||
let [mouseX, mouseY] = global.get_pointer();
|
|
||||||
let [x, y] = this._controls.get_transformed_position();
|
|
||||||
let [width, height] = this._controls.get_transformed_size();
|
|
||||||
let visibleWidth = this._controls.get_theme_node().get_length('visible-width');
|
|
||||||
let rtl = (Clutter.get_default_text_direction () == Clutter.TextDirection.RTL);
|
|
||||||
if(rtl)
|
|
||||||
x = x + width - visibleWidth;
|
|
||||||
if(mouseX > x - 0.5 && mouseX < x + visibleWidth + 0.5 &&
|
|
||||||
mouseY > y - 0.5 && mouseY < y + height + 0.5)
|
|
||||||
this._controlsInitiallyHovered = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
this._zoomOut = this._alwaysZoomOut;
|
|
||||||
this._zoomFraction = this._alwaysZoomOut ? 1 : 0;
|
|
||||||
this._updateZoom();
|
|
||||||
|
|
||||||
this._controls.show();
|
|
||||||
this._thumbnailsBox.show();
|
|
||||||
this._updateSwitcherVisibility();
|
|
||||||
|
|
||||||
this._updateWorkspacesViews();
|
this._updateWorkspacesViews();
|
||||||
|
|
||||||
this._restackedNotifyId =
|
this._restackedNotifyId =
|
||||||
global.screen.connect('restacked',
|
Main.overview.connect('sync-window-stacking',
|
||||||
Lang.bind(this, this._onRestacked));
|
Lang.bind(this, this._onRestacked));
|
||||||
|
|
||||||
if (this._itemDragBeginId == 0)
|
if (this._appDragBeginId == 0)
|
||||||
this._itemDragBeginId = Main.overview.connect('item-drag-begin',
|
this._appDragBeginId = Main.overview.connect('app-drag-begin',
|
||||||
Lang.bind(this, this._dragBegin));
|
Lang.bind(this, this._dragBegin));
|
||||||
if (this._itemDragCancelledId == 0)
|
if (this._appDragCancelledId == 0)
|
||||||
this._itemDragCancelledId = Main.overview.connect('item-drag-cancelled',
|
this._appDragCancelledId = Main.overview.connect('app-drag-cancelled',
|
||||||
Lang.bind(this, this._dragCancelled));
|
Lang.bind(this, this._dragCancelled));
|
||||||
if (this._itemDragEndId == 0)
|
if (this._appDragEndId == 0)
|
||||||
this._itemDragEndId = Main.overview.connect('item-drag-end',
|
this._appDragEndId = Main.overview.connect('app-drag-end',
|
||||||
Lang.bind(this, this._dragEnd));
|
Lang.bind(this, this._dragEnd));
|
||||||
if (this._windowDragBeginId == 0)
|
if (this._windowDragBeginId == 0)
|
||||||
this._windowDragBeginId = Main.overview.connect('window-drag-begin',
|
this._windowDragBeginId = Main.overview.connect('window-drag-begin',
|
||||||
@ -583,8 +523,6 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
if (this._windowDragEndId == 0)
|
if (this._windowDragEndId == 0)
|
||||||
this._windowDragEndId = Main.overview.connect('window-drag-end',
|
this._windowDragEndId = Main.overview.connect('window-drag-end',
|
||||||
Lang.bind(this, this._dragEnd));
|
Lang.bind(this, this._dragEnd));
|
||||||
|
|
||||||
this._onRestacked();
|
|
||||||
},
|
},
|
||||||
|
|
||||||
zoomFromOverview: function() {
|
zoomFromOverview: function() {
|
||||||
@ -594,27 +532,21 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
hide: function() {
|
hide: function() {
|
||||||
this._controls.hide();
|
|
||||||
this._thumbnailsBox.hide();
|
|
||||||
|
|
||||||
if (!this._alwaysZoomOut)
|
|
||||||
this.zoomFraction = 0;
|
|
||||||
|
|
||||||
if (this._restackedNotifyId > 0){
|
if (this._restackedNotifyId > 0){
|
||||||
global.screen.disconnect(this._restackedNotifyId);
|
Main.overview.disconnect(this._restackedNotifyId);
|
||||||
this._restackedNotifyId = 0;
|
this._restackedNotifyId = 0;
|
||||||
}
|
}
|
||||||
if (this._itemDragBeginId > 0) {
|
if (this._appDragBeginId > 0) {
|
||||||
Main.overview.disconnect(this._itemDragBeginId);
|
Main.overview.disconnect(this._appDragBeginId);
|
||||||
this._itemDragBeginId = 0;
|
this._appDragBeginId = 0;
|
||||||
}
|
}
|
||||||
if (this._itemDragCancelledId > 0) {
|
if (this._appDragCancelledId > 0) {
|
||||||
Main.overview.disconnect(this._itemDragCancelledId);
|
Main.overview.disconnect(this._appDragCancelledId);
|
||||||
this._itemDragCancelledId = 0;
|
this._appDragCancelledId = 0;
|
||||||
}
|
}
|
||||||
if (this._itemDragEndId > 0) {
|
if (this._appDragEndId > 0) {
|
||||||
Main.overview.disconnect(this._itemDragEndId);
|
Main.overview.disconnect(this._appDragEndId);
|
||||||
this._itemDragEndId = 0;
|
this._appDragEndId = 0;
|
||||||
}
|
}
|
||||||
if (this._windowDragBeginId > 0) {
|
if (this._windowDragBeginId > 0) {
|
||||||
Main.overview.disconnect(this._windowDragBeginId);
|
Main.overview.disconnect(this._windowDragBeginId);
|
||||||
@ -745,73 +677,15 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
return this._getPrimaryView().getActiveWorkspace().hasMaximizedWindows();
|
return this._getPrimaryView().getActiveWorkspace().hasMaximizedWindows();
|
||||||
},
|
},
|
||||||
|
|
||||||
// zoomFraction property allows us to tween the controls sliding in and out
|
|
||||||
set zoomFraction(fraction) {
|
|
||||||
this._zoomFraction = fraction;
|
|
||||||
this.actor.queue_relayout();
|
|
||||||
},
|
|
||||||
|
|
||||||
get zoomFraction() {
|
|
||||||
return this._zoomFraction;
|
|
||||||
},
|
|
||||||
|
|
||||||
_updateAlwaysZoom: function() {
|
|
||||||
// Always show the pager if workspaces are actually used,
|
|
||||||
// e.g. there are windows on more than one
|
|
||||||
this._alwaysZoomOut = global.screen.n_workspaces > 2;
|
|
||||||
|
|
||||||
if (this._alwaysZoomOut)
|
|
||||||
return;
|
|
||||||
|
|
||||||
let monitors = Main.layoutManager.monitors;
|
|
||||||
let primary = Main.layoutManager.primaryMonitor;
|
|
||||||
|
|
||||||
/* Look for any monitor to the right of the primary, if there is
|
|
||||||
* one, we always keep zoom out, otherwise its hard to reach
|
|
||||||
* the thumbnail area without passing into the next monitor. */
|
|
||||||
for (let i = 0; i < monitors.length; i++) {
|
|
||||||
if (monitors[i].x >= primary.x + primary.width) {
|
|
||||||
this._alwaysZoomOut = true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
_getPreferredWidth: function (actor, forHeight, alloc) {
|
_getPreferredWidth: function (actor, forHeight, alloc) {
|
||||||
// pass through the call in case the child needs it, but report 0x0
|
// pass through the call in case the child needs it, but report 0x0
|
||||||
this._controls.get_preferred_width(forHeight);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_getPreferredHeight: function (actor, forWidth, alloc) {
|
_getPreferredHeight: function (actor, forWidth, alloc) {
|
||||||
// pass through the call in case the child needs it, but report 0x0
|
// pass through the call in case the child needs it, but report 0x0
|
||||||
this._controls.get_preferred_height(forWidth);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_allocate: function (actor, box, flags) {
|
_allocate: function (actor, box, flags) {
|
||||||
let childBox = new Clutter.ActorBox();
|
|
||||||
|
|
||||||
let totalWidth = box.x2 - box.x1;
|
|
||||||
|
|
||||||
// width of the controls
|
|
||||||
let [controlsMin, controlsNatural] = this._controls.get_preferred_width(box.y2 - box.y1);
|
|
||||||
|
|
||||||
// Amount of space on the screen we reserve for the visible control
|
|
||||||
let controlsVisible = this._controls.get_theme_node().get_length('visible-width');
|
|
||||||
let controlsReserved = controlsVisible * (1 - this._zoomFraction) + controlsNatural * this._zoomFraction;
|
|
||||||
|
|
||||||
let rtl = (Clutter.get_default_text_direction () == Clutter.TextDirection.RTL);
|
|
||||||
if (rtl) {
|
|
||||||
childBox.x2 = controlsReserved;
|
|
||||||
childBox.x1 = childBox.x2 - controlsNatural;
|
|
||||||
} else {
|
|
||||||
childBox.x1 = totalWidth - controlsReserved;
|
|
||||||
childBox.x2 = childBox.x1 + controlsNatural;
|
|
||||||
}
|
|
||||||
|
|
||||||
childBox.y1 = 0;
|
|
||||||
childBox.y2 = box.y2- box.y1;
|
|
||||||
this._controls.allocate(childBox, flags);
|
|
||||||
|
|
||||||
this._updateWorkspacesGeometry();
|
this._updateWorkspacesGeometry();
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -851,24 +725,15 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
let width = fullWidth;
|
let width = fullWidth;
|
||||||
let height = fullHeight;
|
let height = fullHeight;
|
||||||
|
|
||||||
let [controlsMin, controlsNatural] = this._controls.get_preferred_width(height);
|
|
||||||
let controlsVisible = this._controls.get_theme_node().get_length('visible-width');
|
|
||||||
|
|
||||||
let [x, y] = this.actor.get_transformed_position();
|
let [x, y] = this.actor.get_transformed_position();
|
||||||
|
|
||||||
let rtl = (Clutter.get_default_text_direction () == Clutter.TextDirection.RTL);
|
let rtl = (Clutter.get_default_text_direction () == Clutter.TextDirection.RTL);
|
||||||
|
|
||||||
let clipWidth = width - controlsVisible;
|
let clipWidth = width;
|
||||||
let clipHeight = fullHeight;
|
let clipHeight = fullHeight;
|
||||||
let clipX = rtl ? x + controlsVisible : x;
|
let clipX = x;
|
||||||
let clipY = y + (fullHeight - clipHeight) / 2;
|
let clipY = y + (fullHeight - clipHeight) / 2;
|
||||||
|
|
||||||
let widthAdjust = this._zoomOut ? controlsNatural : controlsVisible;
|
|
||||||
widthAdjust += Main.overview._spacing;
|
|
||||||
width -= widthAdjust;
|
|
||||||
if (rtl)
|
|
||||||
x += widthAdjust;
|
|
||||||
|
|
||||||
let monitors = Main.layoutManager.monitors;
|
let monitors = Main.layoutManager.monitors;
|
||||||
let m = 0;
|
let m = 0;
|
||||||
for (let i = 0; i < monitors.length; i++) {
|
for (let i = 0; i < monitors.length; i++) {
|
||||||
@ -891,25 +756,12 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
_onRestacked: function() {
|
_onRestacked: function(actor, stackIndices) {
|
||||||
let stack = global.get_window_actors();
|
|
||||||
let stackIndices = {};
|
|
||||||
|
|
||||||
for (let i = 0; i < stack.length; i++) {
|
|
||||||
// Use the stable sequence for an integer to use as a hash key
|
|
||||||
stackIndices[stack[i].get_meta_window().get_stable_sequence()] = i;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (let i = 0; i < this._workspacesViews.length; i++)
|
for (let i = 0; i < this._workspacesViews.length; i++)
|
||||||
this._workspacesViews[i].syncStacking(stackIndices);
|
this._workspacesViews[i].syncStacking(stackIndices);
|
||||||
|
|
||||||
this._thumbnailsBox.syncStacking(stackIndices);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
_workspacesChanged: function() {
|
_workspacesChanged: function() {
|
||||||
this._updateAlwaysZoom();
|
|
||||||
this._updateZoom();
|
|
||||||
|
|
||||||
if (this._workspacesViews == null)
|
if (this._workspacesViews == null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -934,8 +786,6 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
}
|
}
|
||||||
m++;
|
m++;
|
||||||
}
|
}
|
||||||
|
|
||||||
this._thumbnailsBox.addThumbnails(oldNumWorkspaces, newNumWorkspaces - oldNumWorkspaces);
|
|
||||||
} else {
|
} else {
|
||||||
// Assume workspaces are only removed sequentially
|
// Assume workspaces are only removed sequentially
|
||||||
// (e.g. 2,3,4 - not 2,4,7)
|
// (e.g. 2,3,4 - not 2,4,7)
|
||||||
@ -958,8 +808,6 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
lostWorkspaces[l].destroy();
|
lostWorkspaces[l].destroy();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this._thumbnailsBox.removeThumbnails(removedIndex, removedNum);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let i = 0; i < this._workspacesViews.length; i++)
|
for (let i = 0; i < this._workspacesViews.length; i++)
|
||||||
@ -968,35 +816,6 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
this._updateSwitcherVisibility();
|
this._updateSwitcherVisibility();
|
||||||
},
|
},
|
||||||
|
|
||||||
_updateZoom : function() {
|
|
||||||
if (Main.overview.animationInProgress)
|
|
||||||
return;
|
|
||||||
|
|
||||||
let shouldZoom = this._alwaysZoomOut || this._controls.hover;
|
|
||||||
if (shouldZoom != this._zoomOut) {
|
|
||||||
this._zoomOut = shouldZoom;
|
|
||||||
this._updateWorkspacesGeometry();
|
|
||||||
|
|
||||||
if (!this._workspacesViews)
|
|
||||||
return;
|
|
||||||
|
|
||||||
Tweener.addTween(this,
|
|
||||||
{ zoomFraction: this._zoomOut ? 1 : 0,
|
|
||||||
time: WORKSPACE_SWITCH_TIME,
|
|
||||||
transition: 'easeOutQuad' });
|
|
||||||
|
|
||||||
for (let i = 0; i < this._workspacesViews.length; i++)
|
|
||||||
this._workspacesViews[i].updateWindowPositions();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
_onControlsHoverChanged: function() {
|
|
||||||
if(!this._controls.hover)
|
|
||||||
this._controlsInitiallyHovered = false;
|
|
||||||
if(!this._controlsInitiallyHovered)
|
|
||||||
this._updateZoom();
|
|
||||||
},
|
|
||||||
|
|
||||||
_dragBegin: function() {
|
_dragBegin: function() {
|
||||||
this._inDrag = true;
|
this._inDrag = true;
|
||||||
this._cancelledDrag = false;
|
this._cancelledDrag = false;
|
||||||
@ -1012,33 +831,11 @@ const WorkspacesDisplay = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_onDragMotion: function(dragEvent) {
|
_onDragMotion: function(dragEvent) {
|
||||||
let controlsHovered = this._controls.contains(dragEvent.targetActor);
|
|
||||||
this._controls.set_hover(controlsHovered);
|
|
||||||
|
|
||||||
return DND.DragMotionResult.CONTINUE;
|
return DND.DragMotionResult.CONTINUE;
|
||||||
},
|
},
|
||||||
|
|
||||||
_dragEnd: function() {
|
_dragEnd: function() {
|
||||||
this._inDrag = false;
|
this._inDrag = false;
|
||||||
|
|
||||||
// We do this deferred because drag-end is emitted before dnd.js emits
|
|
||||||
// event/leave events that were suppressed during the drag. If we didn't
|
|
||||||
// defer this, we'd zoom out then immediately zoom in because of the
|
|
||||||
// enter event we received. That would normally be invisible but we
|
|
||||||
// might as well avoid it.
|
|
||||||
Meta.later_add(Meta.LaterType.BEFORE_REDRAW,
|
|
||||||
Lang.bind(this, this._updateZoom));
|
|
||||||
},
|
|
||||||
|
|
||||||
_onScrollEvent: function (actor, event) {
|
|
||||||
switch ( event.get_scroll_direction() ) {
|
|
||||||
case Clutter.ScrollDirection.UP:
|
|
||||||
Main.wm.actionMoveWorkspace(Meta.MotionDirection.UP);
|
|
||||||
break;
|
|
||||||
case Clutter.ScrollDirection.DOWN:
|
|
||||||
Main.wm.actionMoveWorkspace(Meta.MotionDirection.DOWN);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Signals.addSignalMethods(WorkspacesDisplay.prototype);
|
Signals.addSignalMethods(WorkspacesDisplay.prototype);
|
||||||
|
@ -1,19 +1 @@
|
|||||||
XSLTPROC_FLAGS = \
|
dist_man_MANS = gnome-shell.1
|
||||||
--nonet \
|
|
||||||
--stringparam man.output.quietly 1 \
|
|
||||||
--stringparam funcsynopsis.style ansi \
|
|
||||||
--stringparam man.th.extra1.suppress 1 \
|
|
||||||
--stringparam man.authors.section.enabled 0 \
|
|
||||||
--stringparam man.copyright.section.enabled 0
|
|
||||||
|
|
||||||
.xml.1:
|
|
||||||
$(AM_V_GEN) $(XSLTPROC) $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
|
|
||||||
|
|
||||||
man_MANS = \
|
|
||||||
gnome-shell.1
|
|
||||||
|
|
||||||
xml_files = $(man_MANS:.1=.xml)
|
|
||||||
|
|
||||||
EXTRA_DIST = $(xml_files)
|
|
||||||
|
|
||||||
DISTCLEANFILES = $(man_MANS)
|
|
||||||
|
94
man/gnome-shell.1
Normal file
94
man/gnome-shell.1
Normal file
@ -0,0 +1,94 @@
|
|||||||
|
.\" Copyright (c) 2009, Marcelo Jorge Vieira (metal) <metal@alucinados.com>
|
||||||
|
.\"
|
||||||
|
.\" This is free documentation; you can redistribute it and/or
|
||||||
|
.\" modify it under the terms of the GNU General Public License as
|
||||||
|
.\" published by the Free Software Foundation; either version 2 of
|
||||||
|
.\" the License, or (at your option) any later version.
|
||||||
|
.\"
|
||||||
|
.\" The GNU General Public License's references to "object code"
|
||||||
|
.\" and "executables" are to be interpreted as the output of any
|
||||||
|
.\" document formatting or typesetting system, including
|
||||||
|
.\" intermediate and printed output.
|
||||||
|
.\"
|
||||||
|
.\" This manual is distributed in the hope that it will be useful,
|
||||||
|
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
.\" GNU General Public License for more details.
|
||||||
|
.\"
|
||||||
|
.\" You should have received a copy of the GNU General Public
|
||||||
|
.\" License along with this manual; if not, write to the Free
|
||||||
|
.\" Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||||
|
.\" Boston, MA 02111-1301 USA.
|
||||||
|
.TH GNOME-SHELL 1
|
||||||
|
.SH NAME
|
||||||
|
gnome-shell \- Graphical shell for the GNOME desktop
|
||||||
|
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.B gnome-shell [options]
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
GNOME Shell provides core user interface functions for the GNOME 3
|
||||||
|
desktop, like switching to windows and launching applications. GNOME
|
||||||
|
Shell takes advantage of the capabilities of modern graphics hardware
|
||||||
|
and introduces innovative user interface concepts to provide a
|
||||||
|
visually attractive and easy to use experience.
|
||||||
|
|
||||||
|
.SH OPTIONS
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-replace
|
||||||
|
Replace the running window manager
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-sm-disable
|
||||||
|
Disable connection to the session manager
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-sm-client-id=ID
|
||||||
|
Specify session management ID
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-sm-save-file=FILE
|
||||||
|
Initialize session from savefile
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-screen=SCREEN
|
||||||
|
X screen to use
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-d, \-\-display=DISPLAY
|
||||||
|
X display to use
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-sync
|
||||||
|
Make X calls synchronous
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-version
|
||||||
|
Print version and exit
|
||||||
|
.br
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-\-help
|
||||||
|
Display help and exit
|
||||||
|
.br
|
||||||
|
|
||||||
|
.SH BUGS
|
||||||
|
The bug tracker can be reached by visiting the website
|
||||||
|
\fIhttps://bugzilla.gnome.org/buglist.cgi?product=gnome-shell\fR
|
||||||
|
|
||||||
|
Before sending a bug report, please verify that you have the latest
|
||||||
|
version of gnome-shell. Many bugs (major and minor) are fixed at each
|
||||||
|
release, and if yours is out of date, the problem may already have
|
||||||
|
been solved.
|
||||||
|
|
||||||
|
.SH ADDITIONAL INFORMATION
|
||||||
|
|
||||||
|
For further information, visit the website \fIhttp://live.gnome.org/GnomeShell\fR
|
@ -1,159 +0,0 @@
|
|||||||
<?xml version='1.0'?>
|
|
||||||
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
|
|
||||||
"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
|
|
||||||
|
|
||||||
<refentry id="gnome-shell">
|
|
||||||
|
|
||||||
<refentryinfo>
|
|
||||||
<title>gnome-shell</title>
|
|
||||||
<productname>gnome-shell</productname>
|
|
||||||
|
|
||||||
<authorgroup>
|
|
||||||
<author>
|
|
||||||
<contrib>wrote the original gnome-shell man page</contrib>
|
|
||||||
<firstname>Marcelo Jorge</firstname>
|
|
||||||
<surname>Vieira</surname>
|
|
||||||
<email>metal@alucinados.com</email>
|
|
||||||
</author>
|
|
||||||
</authorgroup>
|
|
||||||
|
|
||||||
</refentryinfo>
|
|
||||||
|
|
||||||
<refmeta>
|
|
||||||
<refentrytitle>gnome-shell</refentrytitle>
|
|
||||||
<manvolnum>1</manvolnum>
|
|
||||||
</refmeta>
|
|
||||||
|
|
||||||
<refnamediv>
|
|
||||||
<refname>gnome-shell</refname>
|
|
||||||
<refpurpose>Graphical shell for the GNOME desktop</refpurpose>
|
|
||||||
</refnamediv>
|
|
||||||
|
|
||||||
<refsynopsisdiv>
|
|
||||||
<cmdsynopsis>
|
|
||||||
<command>gnome-shell <arg choice="opt" rep="repeat">OPTION</arg></command>
|
|
||||||
</cmdsynopsis>
|
|
||||||
</refsynopsisdiv>
|
|
||||||
|
|
||||||
<refsect1>
|
|
||||||
<title>Description</title>
|
|
||||||
|
|
||||||
<para>GNOME shell provides core user
|
|
||||||
interface functions for the GNOME 3 desktop, like switching
|
|
||||||
to windows and launching applications. GNOME shell takes
|
|
||||||
advantage of the capabilities of modern graphics hardware
|
|
||||||
and introduces innovative user interface concepts to provide
|
|
||||||
a visually attractive and easy to use experience.</para>
|
|
||||||
|
|
||||||
<para>gnome-shell is a required component of
|
|
||||||
the GNOME desktop, i.e. it is listed in the
|
|
||||||
RequiredComponents field of
|
|
||||||
<filename>/usr/share/gnome-session/sessions/gnome.session</filename>.
|
|
||||||
It is started in the window manager phase of the session.
|
|
||||||
</para>
|
|
||||||
|
|
||||||
</refsect1>
|
|
||||||
|
|
||||||
<refsect1>
|
|
||||||
<title>Options</title>
|
|
||||||
|
|
||||||
<variablelist>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>-r</option>, <option>--replace</option></term>
|
|
||||||
|
|
||||||
<listitem><para>Replace the running window manager</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--sm-disable</option></term>
|
|
||||||
|
|
||||||
<listitem><para>Disable connection to the session manager</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--sm-client-id=<replaceable>ID</replaceable></option></term>
|
|
||||||
|
|
||||||
<listitem><para>Specify session management <replaceable>ID</replaceable></para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--sm-save-file=<replaceable>FILE</replaceable></option></term>
|
|
||||||
|
|
||||||
<listitem><para>Initialize session from <replaceable>FILE</replaceable></para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--screen=<replaceable>SCREEN</replaceable></option></term>
|
|
||||||
|
|
||||||
<listitem><para>X screen to use</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>-d</option>, <option>--display=<replaceable>DISPLAY</replaceable></option></term>
|
|
||||||
|
|
||||||
<listitem><para>X Display to use</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--sync</option></term>
|
|
||||||
|
|
||||||
<listitem><para>Make X calls synchronous</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--version</option></term>
|
|
||||||
|
|
||||||
<listitem><para>Print version and exit</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--help</option></term>
|
|
||||||
|
|
||||||
<listitem><para>Display help and exit</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--mode=<replaceable>MODE</replaceable></option></term>
|
|
||||||
|
|
||||||
<listitem><para>Use a specific mode, e.g. "gdm" for login screen</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term><option>--list-modes</option></term>
|
|
||||||
|
|
||||||
<listitem><para>List possible modes and exit</para></listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
</variablelist>
|
|
||||||
|
|
||||||
</refsect1>
|
|
||||||
|
|
||||||
<refsect1>
|
|
||||||
<title>Files</title>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
<filename>/usr/share/gnome-session/sessions/gnome.session</filename>,
|
|
||||||
<filename>/usr/share/applications/gnome-shell.desktop</filename>.</para>
|
|
||||||
</refsect1>
|
|
||||||
|
|
||||||
<refsect1>
|
|
||||||
<title>Bugs</title>
|
|
||||||
|
|
||||||
<para>The bug tracker can be reached by visiting the
|
|
||||||
website <ulink url="https://bugzilla.gnome.org/buglist.cgi?product=gnome-shell">https://bugzilla.gnome.org/buglist.cgi?product=gnome-shell</ulink>.
|
|
||||||
Before sending a bug report, please verify that you have
|
|
||||||
the latest version of gnome-shell. Many bugs (major and
|
|
||||||
minor) are fixed at each release, and if yours is out of
|
|
||||||
date, the problem may already have been solved.</para>
|
|
||||||
|
|
||||||
</refsect1>
|
|
||||||
|
|
||||||
<refsect1>
|
|
||||||
<title>Additional Information</title>
|
|
||||||
|
|
||||||
<para>For further information, visit the website
|
|
||||||
<ulink url="http://live.gnome.org/GnomeShell">http://live.gnome.org/GnomeShell</ulink>.</para>
|
|
||||||
</refsect1>
|
|
||||||
|
|
||||||
</refentry>
|
|
194
po/de.po
194
po/de.po
@ -19,9 +19,9 @@ msgstr ""
|
|||||||
"Project-Id-Version: gnome-shell master\n"
|
"Project-Id-Version: gnome-shell master\n"
|
||||||
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-"
|
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-"
|
||||||
"shell&keywords=I18N+L10N&component=general\n"
|
"shell&keywords=I18N+L10N&component=general\n"
|
||||||
"POT-Creation-Date: 2012-11-06 04:39+0000\n"
|
"POT-Creation-Date: 2012-10-14 16:48+0000\n"
|
||||||
"PO-Revision-Date: 2012-11-06 20:04+0100\n"
|
"PO-Revision-Date: 2012-10-10 23:10+0100\n"
|
||||||
"Last-Translator: Wolfgang Stoeggl <c72578@yahoo.de>\n"
|
"Last-Translator: Tobias Endrigkeit <tobiasendrigkeit@googlemail.com>\n"
|
||||||
"Language-Team: Deutsch <gnome-de@gnome.org>\n"
|
"Language-Team: Deutsch <gnome-de@gnome.org>\n"
|
||||||
"Language: \n"
|
"Language: \n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
@ -148,68 +148,56 @@ msgstr ""
|
|||||||
"Aufzählung entnommen."
|
"Aufzählung entnommen."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
||||||
msgid "Always show the 'Log out' menuitem in the user menu."
|
|
||||||
msgstr "Den Menüeintrag »Abmelden« immer im Benutzermenü anzeigen."
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
|
||||||
msgid ""
|
|
||||||
"This key overrides the automatic hiding of the 'Log out' menuitem in single-"
|
|
||||||
"user, single-session situations."
|
|
||||||
msgstr ""
|
|
||||||
"Dieser Schlüssel überschreibt das automatische Verbergen des Menüeintrags "
|
|
||||||
"»Abmelden« in Einzelbenutzer, Einzelsitzungssituationen."
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
|
||||||
msgid "Show the week date in the calendar"
|
msgid "Show the week date in the calendar"
|
||||||
msgstr "Wochentag im Kalender anzeigen"
|
msgstr "Wochentag im Kalender anzeigen"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
||||||
msgid "If true, display the ISO week date in the calendar."
|
msgid "If true, display the ISO week date in the calendar."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Wenn dieser Wert gesetzt ist, wird der ISO-Wochentag im Kalender angezeigt."
|
"Wenn dieser Wert gesetzt ist, wird der ISO-Wochentag im Kalender angezeigt."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
||||||
msgid "Keybinding to open the application menu"
|
msgid "Keybinding to open the application menu"
|
||||||
msgstr "Tastenkombination zum Öffnen des Anwendungsmenüs"
|
msgstr "Tastenkombination zum Öffnen des Anwendungsmenüs"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
||||||
msgid "Keybinding to open the application menu."
|
msgid "Keybinding to open the application menu."
|
||||||
msgstr "Tastenkombination zum Öffnen des Anwendungsmenüs."
|
msgstr "Tastenkombination zum Öffnen des Anwendungsmenüs."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
||||||
msgid "Keybinding to toggle the visibility of the message tray"
|
msgid "Keybinding to toggle the visibility of the message tray"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Tastenkombination zum Umschalten der Sichtbarkeit des Benachrichtigungsfeldes"
|
"Tastenkombination zum Umschalten der Sichtbarkeit des Benachrichtigungsfeldes"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
||||||
msgid "Keybinding to toggle the visibility of the message tray."
|
msgid "Keybinding to toggle the visibility of the message tray."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Tastenkombination zum Umschalten der Sichtbarkeit des "
|
"Tastenkombination zum Umschalten der Sichtbarkeit des "
|
||||||
"Benachrichtigungsfeldes."
|
"Benachrichtigungsfeldes."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
||||||
msgid "Keybinding to toggle the screen recorder"
|
msgid "Keybinding to toggle the screen recorder"
|
||||||
msgstr "Tastenkombination zum Umschalten des Bildschirmaufzeichners"
|
msgstr "Tastenkombination zum Umschalten des Bildschirmaufzeichners"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
||||||
msgid "Keybinding to start/stop the builtin screen recorder."
|
msgid "Keybinding to start/stop the builtin screen recorder."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Tastenkombination zum Starten/Entfernen des eingebauten "
|
"Tastenkombination zum Starten/Entfernen des eingebauten "
|
||||||
"Bildschirmaufzeichners."
|
"Bildschirmaufzeichners."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
||||||
msgid "Which keyboard to use"
|
msgid "Which keyboard to use"
|
||||||
msgstr "Zu verwendende Tastatur"
|
msgstr "Zu verwendende Tastatur"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
||||||
msgid "The type of keyboard to use."
|
msgid "The type of keyboard to use."
|
||||||
msgstr "Der Typ der zu verwendenden Tastatur"
|
msgstr "Der Typ der zu verwendenden Tastatur"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
||||||
msgid "Framerate used for recording screencasts."
|
msgid "Framerate used for recording screencasts."
|
||||||
msgstr "Bildwiederholungsrate zur Aufnahme von Screencasts"
|
msgstr "Bildwiederholungsrate zur Aufnahme von Screencasts"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:26
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
||||||
msgid ""
|
msgid ""
|
||||||
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
||||||
"screencast recorder in frames-per-second."
|
"screencast recorder in frames-per-second."
|
||||||
@ -218,11 +206,11 @@ msgstr ""
|
|||||||
"der GNOME-Shell aufgezeichnet werden soll, in Einzelbildern pro Sekunde."
|
"der GNOME-Shell aufgezeichnet werden soll, in Einzelbildern pro Sekunde."
|
||||||
|
|
||||||
# hmm Enkodieren oder Kodieren?
|
# hmm Enkodieren oder Kodieren?
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
||||||
msgid "The gstreamer pipeline used to encode the screencast"
|
msgid "The gstreamer pipeline used to encode the screencast"
|
||||||
msgstr "Die GStreamer-Weiterleitung zur Enkodierung des Screencasts"
|
msgstr "Die GStreamer-Weiterleitung zur Enkodierung des Screencasts"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid ""
|
msgid ""
|
||||||
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
||||||
@ -250,11 +238,11 @@ msgstr ""
|
|||||||
"aufzeichnet. %T wird als Platzhalter für die vermutete optimale Thread-"
|
"aufzeichnet. %T wird als Platzhalter für die vermutete optimale Thread-"
|
||||||
"Anzahl auf dem System verwendet."
|
"Anzahl auf dem System verwendet."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:30
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:28
|
||||||
msgid "File extension used for storing the screencast"
|
msgid "File extension used for storing the screencast"
|
||||||
msgstr "Die Dateiendung zum Speichern des Screencast"
|
msgstr "Die Dateiendung zum Speichern des Screencast"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:31
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
||||||
msgid ""
|
msgid ""
|
||||||
"The filename for recorded screencasts will be a unique filename based on the "
|
"The filename for recorded screencasts will be a unique filename based on the "
|
||||||
"current date, and use this extension. It should be changed when recording to "
|
"current date, and use this extension. It should be changed when recording to "
|
||||||
@ -315,8 +303,8 @@ msgstr "Anmeldefenster"
|
|||||||
msgid "Power"
|
msgid "Power"
|
||||||
msgstr "Ausschalten"
|
msgstr "Ausschalten"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:89 ../js/ui/userMenu.js:664 ../js/ui/userMenu.js:668
|
#: ../js/gdm/powerMenu.js:89 ../js/ui/userMenu.js:660 ../js/ui/userMenu.js:664
|
||||||
#: ../js/ui/userMenu.js:779
|
#: ../js/ui/userMenu.js:775
|
||||||
msgid "Suspend"
|
msgid "Suspend"
|
||||||
msgstr "Bereitschaft"
|
msgstr "Bereitschaft"
|
||||||
|
|
||||||
@ -324,8 +312,8 @@ msgstr "Bereitschaft"
|
|||||||
msgid "Restart"
|
msgid "Restart"
|
||||||
msgstr "Neu starten"
|
msgstr "Neu starten"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:99 ../js/ui/userMenu.js:666 ../js/ui/userMenu.js:668
|
#: ../js/gdm/powerMenu.js:99 ../js/ui/userMenu.js:662 ../js/ui/userMenu.js:664
|
||||||
#: ../js/ui/userMenu.js:778
|
#: ../js/ui/userMenu.js:774
|
||||||
msgid "Power Off"
|
msgid "Power Off"
|
||||||
msgstr "Ausschalten"
|
msgstr "Ausschalten"
|
||||||
|
|
||||||
@ -710,35 +698,35 @@ msgstr "Stumm"
|
|||||||
#. Translators: this is a time format string followed by a date.
|
#. Translators: this is a time format string followed by a date.
|
||||||
#. If applicable, replace %X with a strftime format valid for your
|
#. If applicable, replace %X with a strftime format valid for your
|
||||||
#. locale, without seconds.
|
#. locale, without seconds.
|
||||||
#: ../js/ui/components/telepathyClient.js:952
|
#: ../js/ui/components/telepathyClient.js:948
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent at <b>%X</b> on <b>%A</b>"
|
msgid "Sent at <b>%X</b> on <b>%A</b>"
|
||||||
msgstr "Gesendet am <b>%A</b> um <b>%X</b> "
|
msgstr "Gesendet am <b>%A</b> um <b>%X</b> "
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "Wednesday, May 25",
|
#. Translators: this is a time format in the style of "Wednesday, May 25",
|
||||||
#. shown when you get a chat message in the same year.
|
#. shown when you get a chat message in the same year.
|
||||||
#: ../js/ui/components/telepathyClient.js:958
|
#: ../js/ui/components/telepathyClient.js:954
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent on <b>%A</b>, <b>%B %d</b>"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>"
|
||||||
msgstr "Gesendet am <b>%A</b>, <b>%d. %B</b>"
|
msgstr "Gesendet am <b>%A</b>, <b>%d. %B</b>"
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "Wednesday, May 25, 2012",
|
#. Translators: this is a time format in the style of "Wednesday, May 25, 2012",
|
||||||
#. shown when you get a chat message in a different year.
|
#. shown when you get a chat message in a different year.
|
||||||
#: ../js/ui/components/telepathyClient.js:963
|
#: ../js/ui/components/telepathyClient.js:959
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent on <b>%A</b>, <b>%B %d</b>, %Y"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>, %Y"
|
||||||
msgstr "Gesendet am <b>%A</b>, <b>%d. %B</b> %Y"
|
msgstr "Gesendet am <b>%A</b>, <b>%d. %B</b> %Y"
|
||||||
|
|
||||||
#. Translators: this is the other person changing their old IM name to their new
|
#. Translators: this is the other person changing their old IM name to their new
|
||||||
#. IM name.
|
#. IM name.
|
||||||
#: ../js/ui/components/telepathyClient.js:992
|
#: ../js/ui/components/telepathyClient.js:988
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is now known as %s"
|
msgid "%s is now known as %s"
|
||||||
msgstr "%s heißt jetzt %s"
|
msgstr "%s heißt jetzt %s"
|
||||||
|
|
||||||
#. translators: argument is a room name like
|
#. translators: argument is a room name like
|
||||||
#. * room@jabber.org for example.
|
#. * room@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1092
|
#: ../js/ui/components/telepathyClient.js:1088
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Invitation to %s"
|
msgid "Invitation to %s"
|
||||||
msgstr "Einladung zum Betreten von %s"
|
msgstr "Einladung zum Betreten von %s"
|
||||||
@ -746,42 +734,42 @@ msgstr "Einladung zum Betreten von %s"
|
|||||||
#. translators: first argument is the name of a contact and the second
|
#. translators: first argument is the name of a contact and the second
|
||||||
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
||||||
#. * for example.
|
#. * for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1100
|
#: ../js/ui/components/telepathyClient.js:1096
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is inviting you to join %s"
|
msgid "%s is inviting you to join %s"
|
||||||
msgstr "%s lädt Sie ein, %s beizutreten"
|
msgstr "%s lädt Sie ein, %s beizutreten"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1102
|
#: ../js/ui/components/telepathyClient.js:1098
|
||||||
#: ../js/ui/components/telepathyClient.js:1181
|
#: ../js/ui/components/telepathyClient.js:1177
|
||||||
#: ../js/ui/components/telepathyClient.js:1244
|
#: ../js/ui/components/telepathyClient.js:1240
|
||||||
msgid "Decline"
|
msgid "Decline"
|
||||||
msgstr "Ablehnen"
|
msgstr "Ablehnen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1103
|
#: ../js/ui/components/telepathyClient.js:1099
|
||||||
#: ../js/ui/components/telepathyClient.js:1182
|
#: ../js/ui/components/telepathyClient.js:1178
|
||||||
#: ../js/ui/components/telepathyClient.js:1245
|
#: ../js/ui/components/telepathyClient.js:1241
|
||||||
msgid "Accept"
|
msgid "Accept"
|
||||||
msgstr "Annehmen"
|
msgstr "Annehmen"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1133
|
#: ../js/ui/components/telepathyClient.js:1129
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Video call from %s"
|
msgid "Video call from %s"
|
||||||
msgstr "Video-Anruf von %s"
|
msgstr "Video-Anruf von %s"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1136
|
#: ../js/ui/components/telepathyClient.js:1132
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Call from %s"
|
msgid "Call from %s"
|
||||||
msgstr "Anruf von %s"
|
msgstr "Anruf von %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1141
|
#: ../js/ui/components/telepathyClient.js:1137
|
||||||
#: ../js/ui/status/bluetooth.js:346
|
#: ../js/ui/status/bluetooth.js:346
|
||||||
msgid "Reject"
|
msgid "Reject"
|
||||||
msgstr "Abweisen"
|
msgstr "Abweisen"
|
||||||
|
|
||||||
#. translators: this is a button label (verb), not a noun
|
#. translators: this is a button label (verb), not a noun
|
||||||
#: ../js/ui/components/telepathyClient.js:1143
|
#: ../js/ui/components/telepathyClient.js:1139
|
||||||
msgid "Answer"
|
msgid "Answer"
|
||||||
msgstr "Antworten"
|
msgstr "Antworten"
|
||||||
|
|
||||||
@ -790,113 +778,113 @@ msgstr "Antworten"
|
|||||||
#. * file name. The string will be something
|
#. * file name. The string will be something
|
||||||
#. * like: "Alice is sending you test.ogg"
|
#. * like: "Alice is sending you test.ogg"
|
||||||
#.
|
#.
|
||||||
#: ../js/ui/components/telepathyClient.js:1175
|
#: ../js/ui/components/telepathyClient.js:1171
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is sending you %s"
|
msgid "%s is sending you %s"
|
||||||
msgstr "%s sendet Ihnen %s"
|
msgstr "%s sendet Ihnen %s"
|
||||||
|
|
||||||
#. To translators: The parameter is the contact's alias
|
#. To translators: The parameter is the contact's alias
|
||||||
#: ../js/ui/components/telepathyClient.js:1210
|
#: ../js/ui/components/telepathyClient.js:1206
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s would like permission to see when you are online"
|
msgid "%s would like permission to see when you are online"
|
||||||
msgstr "%s bittet um das Recht, Ihre Online-Verfügbarkeit sehen zu dürfen"
|
msgstr "%s bittet um das Recht, Ihre Online-Verfügbarkeit sehen zu dürfen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1302
|
#: ../js/ui/components/telepathyClient.js:1298
|
||||||
msgid "Network error"
|
msgid "Network error"
|
||||||
msgstr "Netzwerkfehler"
|
msgstr "Netzwerkfehler"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1304
|
#: ../js/ui/components/telepathyClient.js:1300
|
||||||
msgid "Authentication failed"
|
msgid "Authentication failed"
|
||||||
msgstr "Legitimierung fehlgeschlagen"
|
msgstr "Legitimierung fehlgeschlagen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1306
|
#: ../js/ui/components/telepathyClient.js:1302
|
||||||
msgid "Encryption error"
|
msgid "Encryption error"
|
||||||
msgstr "Verschlüsselungsfehler"
|
msgstr "Verschlüsselungsfehler"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1308
|
#: ../js/ui/components/telepathyClient.js:1304
|
||||||
msgid "Certificate not provided"
|
msgid "Certificate not provided"
|
||||||
msgstr "Zertifikat wurde nicht bereitgestellt"
|
msgstr "Zertifikat wurde nicht bereitgestellt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1310
|
#: ../js/ui/components/telepathyClient.js:1306
|
||||||
msgid "Certificate untrusted"
|
msgid "Certificate untrusted"
|
||||||
msgstr "Zertifikat nicht vertrauenswürdig"
|
msgstr "Zertifikat nicht vertrauenswürdig"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1312
|
#: ../js/ui/components/telepathyClient.js:1308
|
||||||
msgid "Certificate expired"
|
msgid "Certificate expired"
|
||||||
msgstr "Zertifikat abgelaufen"
|
msgstr "Zertifikat abgelaufen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1314
|
#: ../js/ui/components/telepathyClient.js:1310
|
||||||
msgid "Certificate not activated"
|
msgid "Certificate not activated"
|
||||||
msgstr "Zertifikat nicht aktiviert"
|
msgstr "Zertifikat nicht aktiviert"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1316
|
#: ../js/ui/components/telepathyClient.js:1312
|
||||||
msgid "Certificate hostname mismatch"
|
msgid "Certificate hostname mismatch"
|
||||||
msgstr "Rechnername des Zertifikats stimmt nicht überein"
|
msgstr "Rechnername des Zertifikats stimmt nicht überein"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1318
|
#: ../js/ui/components/telepathyClient.js:1314
|
||||||
msgid "Certificate fingerprint mismatch"
|
msgid "Certificate fingerprint mismatch"
|
||||||
msgstr "Fingerabdruck des Zertifikats stimmt nicht überein"
|
msgstr "Fingerabdruck des Zertifikats stimmt nicht überein"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1320
|
#: ../js/ui/components/telepathyClient.js:1316
|
||||||
msgid "Certificate self-signed"
|
msgid "Certificate self-signed"
|
||||||
msgstr "Selbstsigniertes Zertifikat"
|
msgstr "Selbstsigniertes Zertifikat"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1322
|
#: ../js/ui/components/telepathyClient.js:1318
|
||||||
msgid "Status is set to offline"
|
msgid "Status is set to offline"
|
||||||
msgstr "Der Status ist auf »Abgemeldet« gesetzt"
|
msgstr "Der Status ist auf »Abgemeldet« gesetzt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1324
|
#: ../js/ui/components/telepathyClient.js:1320
|
||||||
msgid "Encryption is not available"
|
msgid "Encryption is not available"
|
||||||
msgstr "Verschlüsselung ist nicht verfügbar"
|
msgstr "Verschlüsselung ist nicht verfügbar"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1326
|
#: ../js/ui/components/telepathyClient.js:1322
|
||||||
msgid "Certificate is invalid"
|
msgid "Certificate is invalid"
|
||||||
msgstr "Zertifikat ist ungültig"
|
msgstr "Zertifikat ist ungültig"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1328
|
#: ../js/ui/components/telepathyClient.js:1324
|
||||||
msgid "Connection has been refused"
|
msgid "Connection has been refused"
|
||||||
msgstr "Verbindungsaufbau wurde verweigert"
|
msgstr "Verbindungsaufbau wurde verweigert"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1330
|
#: ../js/ui/components/telepathyClient.js:1326
|
||||||
msgid "Connection can't be established"
|
msgid "Connection can't be established"
|
||||||
msgstr "Verbindung kann nicht hergestellt werden"
|
msgstr "Verbindung kann nicht hergestellt werden"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1332
|
#: ../js/ui/components/telepathyClient.js:1328
|
||||||
msgid "Connection has been lost"
|
msgid "Connection has been lost"
|
||||||
msgstr "Verbindung wurde unterbrochen"
|
msgstr "Verbindung wurde unterbrochen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1334
|
#: ../js/ui/components/telepathyClient.js:1330
|
||||||
msgid "This account is already connected to the server"
|
msgid "This account is already connected to the server"
|
||||||
msgstr "Dieses Konto ist bereits mit dem Server verbunden"
|
msgstr "Dieses Konto ist bereits mit dem Server verbunden"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1336
|
#: ../js/ui/components/telepathyClient.js:1332
|
||||||
msgid ""
|
msgid ""
|
||||||
"Connection has been replaced by a new connection using the same resource"
|
"Connection has been replaced by a new connection using the same resource"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Die Verbindung wurde durch eine neue Verbindung mit der gleichen Ressource "
|
"Die Verbindung wurde durch eine neue Verbindung mit der gleichen Ressource "
|
||||||
"ersetzt"
|
"ersetzt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1338
|
#: ../js/ui/components/telepathyClient.js:1334
|
||||||
msgid "The account already exists on the server"
|
msgid "The account already exists on the server"
|
||||||
msgstr "Dieses Konto ist bereits auf dem Server vorhanden"
|
msgstr "Dieses Konto ist bereits auf dem Server vorhanden"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1340
|
#: ../js/ui/components/telepathyClient.js:1336
|
||||||
msgid "Server is currently too busy to handle the connection"
|
msgid "Server is currently too busy to handle the connection"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Der Server ist derzeit überlastet und kann die Verbindung nicht annehmen"
|
"Der Server ist derzeit überlastet und kann die Verbindung nicht annehmen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1342
|
#: ../js/ui/components/telepathyClient.js:1338
|
||||||
msgid "Certificate has been revoked"
|
msgid "Certificate has been revoked"
|
||||||
msgstr "Zertifikat wurde zurückgezogen"
|
msgstr "Zertifikat wurde zurückgezogen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1344
|
#: ../js/ui/components/telepathyClient.js:1340
|
||||||
msgid ""
|
msgid ""
|
||||||
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Das Zertifikat verwendet einen unsicheren Chiffrier-Algorithmus oder ist "
|
"Das Zertifikat verwendet einen unsicheren Chiffrier-Algorithmus oder ist "
|
||||||
"kryptografisch schwach"
|
"kryptografisch schwach"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1346
|
#: ../js/ui/components/telepathyClient.js:1342
|
||||||
msgid ""
|
msgid ""
|
||||||
"The length of the server certificate, or the depth of the server certificate "
|
"The length of the server certificate, or the depth of the server certificate "
|
||||||
"chain, exceed the limits imposed by the cryptography library"
|
"chain, exceed the limits imposed by the cryptography library"
|
||||||
@ -905,26 +893,26 @@ msgstr ""
|
|||||||
"überschreiten die durch die kryptografische Bibliothek gegebenen "
|
"überschreiten die durch die kryptografische Bibliothek gegebenen "
|
||||||
"Beschränkungen"
|
"Beschränkungen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1348
|
#: ../js/ui/components/telepathyClient.js:1344
|
||||||
msgid "Internal error"
|
msgid "Internal error"
|
||||||
msgstr "Interner Fehler"
|
msgstr "Interner Fehler"
|
||||||
|
|
||||||
#. translators: argument is the account name, like
|
#. translators: argument is the account name, like
|
||||||
#. * name@jabber.org for example.
|
#. * name@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1358
|
#: ../js/ui/components/telepathyClient.js:1354
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Connection to %s failed"
|
msgid "Connection to %s failed"
|
||||||
msgstr "Verbindung zu %s ist fehlgeschlagen"
|
msgstr "Verbindung zu %s ist fehlgeschlagen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1367
|
#: ../js/ui/components/telepathyClient.js:1363
|
||||||
msgid "Reconnect"
|
msgid "Reconnect"
|
||||||
msgstr "Erneut verbinden"
|
msgstr "Erneut verbinden"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1368
|
#: ../js/ui/components/telepathyClient.js:1364
|
||||||
msgid "Edit account"
|
msgid "Edit account"
|
||||||
msgstr "Konto bearbeiten"
|
msgstr "Konto bearbeiten"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1413
|
#: ../js/ui/components/telepathyClient.js:1409
|
||||||
msgid "Unknown reason"
|
msgid "Unknown reason"
|
||||||
msgstr "Unbekannter Grund"
|
msgstr "Unbekannter Grund"
|
||||||
|
|
||||||
@ -1107,23 +1095,23 @@ msgstr "Quelle zeigen"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Webseite"
|
msgstr "Webseite"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1084
|
#: ../js/ui/messageTray.js:1081
|
||||||
msgid "Open"
|
msgid "Open"
|
||||||
msgstr "Öffnen"
|
msgstr "Öffnen"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1091
|
#: ../js/ui/messageTray.js:1088
|
||||||
msgid "Remove"
|
msgid "Remove"
|
||||||
msgstr "Entfernen"
|
msgstr "Entfernen"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1543
|
#: ../js/ui/messageTray.js:1540
|
||||||
msgid "Message Tray"
|
msgid "Message Tray"
|
||||||
msgstr "Benachrichtigungsfeld"
|
msgstr "Benachrichtigungsfeld"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:2549
|
#: ../js/ui/messageTray.js:2547
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Systeminformationen"
|
msgstr "Systeminformationen"
|
||||||
|
|
||||||
#: ../js/ui/notificationDaemon.js:506 ../src/shell-app.c:374
|
#: ../js/ui/notificationDaemon.js:506 ../src/shell-app.c:373
|
||||||
msgctxt "program"
|
msgctxt "program"
|
||||||
msgid "Unknown"
|
msgid "Unknown"
|
||||||
msgstr "Unbekannt"
|
msgstr "Unbekannt"
|
||||||
@ -1183,18 +1171,18 @@ msgstr "Bitte geben Sie einen Befehl ein:"
|
|||||||
# %B - ausgeschriebener Name des Monats, abhängig von der gesetzten Umgebung
|
# %B - ausgeschriebener Name des Monats, abhängig von der gesetzten Umgebung
|
||||||
#. Translators: This is a time format for a date in
|
#. Translators: This is a time format for a date in
|
||||||
#. long format
|
#. long format
|
||||||
#: ../js/ui/screenShield.js:80
|
#: ../js/ui/screenShield.js:79
|
||||||
msgid "%A, %B %d"
|
msgid "%A, %B %d"
|
||||||
msgstr "%A, %d. %B"
|
msgstr "%A, %d. %B"
|
||||||
|
|
||||||
#: ../js/ui/screenShield.js:144
|
#: ../js/ui/screenShield.js:143
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%d new message"
|
msgid "%d new message"
|
||||||
msgid_plural "%d new messages"
|
msgid_plural "%d new messages"
|
||||||
msgstr[0] "%d neue Nachricht"
|
msgstr[0] "%d neue Nachricht"
|
||||||
msgstr[1] "%d neue Nachrichten"
|
msgstr[1] "%d neue Nachrichten"
|
||||||
|
|
||||||
#: ../js/ui/screenShield.js:146
|
#: ../js/ui/screenShield.js:145
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%d new notification"
|
msgid "%d new notification"
|
||||||
msgid_plural "%d new notifications"
|
msgid_plural "%d new notifications"
|
||||||
@ -1650,59 +1638,59 @@ msgstr "Mikrofon"
|
|||||||
msgid "Log in as another user"
|
msgid "Log in as another user"
|
||||||
msgstr "Als anderer Benutzer anmelden"
|
msgstr "Als anderer Benutzer anmelden"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:181
|
#: ../js/ui/userMenu.js:180
|
||||||
msgid "Available"
|
msgid "Available"
|
||||||
msgstr "Verfügbar"
|
msgstr "Verfügbar"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:184
|
#: ../js/ui/userMenu.js:183
|
||||||
msgid "Busy"
|
msgid "Busy"
|
||||||
msgstr "Beschäftigt"
|
msgstr "Beschäftigt"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:187
|
#: ../js/ui/userMenu.js:186
|
||||||
msgid "Invisible"
|
msgid "Invisible"
|
||||||
msgstr "Unsichtbar"
|
msgstr "Unsichtbar"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:190
|
#: ../js/ui/userMenu.js:189
|
||||||
msgid "Away"
|
msgid "Away"
|
||||||
msgstr "Abwesend"
|
msgstr "Abwesend"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:193
|
#: ../js/ui/userMenu.js:192
|
||||||
msgid "Idle"
|
msgid "Idle"
|
||||||
msgstr "Untätig"
|
msgstr "Untätig"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:196
|
#: ../js/ui/userMenu.js:195
|
||||||
msgid "Unavailable"
|
msgid "Unavailable"
|
||||||
msgstr "Nicht verfügbar"
|
msgstr "Nicht verfügbar"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:744
|
#: ../js/ui/userMenu.js:740
|
||||||
msgid "Notifications"
|
msgid "Notifications"
|
||||||
msgstr "Benachrichtigungen"
|
msgstr "Benachrichtigungen"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:752
|
#: ../js/ui/userMenu.js:748
|
||||||
msgid "System Settings"
|
msgid "System Settings"
|
||||||
msgstr "Systemeinstellungen"
|
msgstr "Systemeinstellungen"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:760
|
#: ../js/ui/userMenu.js:756
|
||||||
msgid "Switch User"
|
msgid "Switch User"
|
||||||
msgstr "Benutzer wechseln"
|
msgstr "Benutzer wechseln"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:765
|
#: ../js/ui/userMenu.js:761
|
||||||
msgid "Log Out"
|
msgid "Log Out"
|
||||||
msgstr "Abmelden"
|
msgstr "Abmelden"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:770
|
#: ../js/ui/userMenu.js:766
|
||||||
msgid "Lock"
|
msgid "Lock"
|
||||||
msgstr "Sperren"
|
msgstr "Sperren"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:785
|
#: ../js/ui/userMenu.js:781
|
||||||
msgid "Install Updates & Restart"
|
msgid "Install Updates & Restart"
|
||||||
msgstr "Aktualisierungen installieren und neustarten"
|
msgstr "Aktualisierungen installieren und neustarten"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:803
|
#: ../js/ui/userMenu.js:799
|
||||||
msgid "Your chat status will be set to busy"
|
msgid "Your chat status will be set to busy"
|
||||||
msgstr "Ihr Anwesenheitsstatus wird auf »Beschäftigt« gesetzt"
|
msgstr "Ihr Anwesenheitsstatus wird auf »Beschäftigt« gesetzt"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:804
|
#: ../js/ui/userMenu.js:800
|
||||||
msgid ""
|
msgid ""
|
||||||
"Notifications are now disabled, including chat messages. Your online status "
|
"Notifications are now disabled, including chat messages. Your online status "
|
||||||
"has been adjusted to let others know that you might not see their messages."
|
"has been adjusted to let others know that you might not see their messages."
|
||||||
@ -1789,7 +1777,7 @@ msgstr ""
|
|||||||
msgid "List possible modes"
|
msgid "List possible modes"
|
||||||
msgstr "Die möglichen Modi auflisten"
|
msgstr "Die möglichen Modi auflisten"
|
||||||
|
|
||||||
#: ../src/shell-app.c:622
|
#: ../src/shell-app.c:621
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Failed to launch '%s'"
|
msgid "Failed to launch '%s'"
|
||||||
msgstr "»%s« konnte nicht gestartet werden"
|
msgstr "»%s« konnte nicht gestartet werden"
|
||||||
|
419
po/nb.po
419
po/nb.po
@ -6,10 +6,10 @@
|
|||||||
# Torstein Adolf Winterseth <kvikende@fsfe.org>, 2010.
|
# Torstein Adolf Winterseth <kvikende@fsfe.org>, 2010.
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: gnome-shell 3.7.x\n"
|
"Project-Id-Version: gnome-shell 3.5.x\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2012-11-05 19:06+0100\n"
|
"POT-Creation-Date: 2012-10-11 20:24+0200\n"
|
||||||
"PO-Revision-Date: 2012-11-05 19:10+0100\n"
|
"PO-Revision-Date: 2012-10-11 20:25+0200\n"
|
||||||
"Last-Translator: Kjartan Maraas <kmaraas@gnome.org>\n"
|
"Last-Translator: Kjartan Maraas <kmaraas@gnome.org>\n"
|
||||||
"Language-Team: Norwegian bokmål <i18n-nb@lister.ping.uio.no>\n"
|
"Language-Team: Norwegian bokmål <i18n-nb@lister.ping.uio.no>\n"
|
||||||
"Language: \n"
|
"Language: \n"
|
||||||
@ -34,14 +34,6 @@ msgstr "System"
|
|||||||
msgid "Show the message tray"
|
msgid "Show the message tray"
|
||||||
msgstr "Vis meldingstrau"
|
msgstr "Vis meldingstrau"
|
||||||
|
|
||||||
#: ../data/50-gnome-shell-system.xml.in.h:3
|
|
||||||
msgid "Show all applications"
|
|
||||||
msgstr "Vis alle programmer"
|
|
||||||
|
|
||||||
#: ../data/50-gnome-shell-system.xml.in.h:4
|
|
||||||
msgid "Open the application menu"
|
|
||||||
msgstr "Åpne programmenyen"
|
|
||||||
|
|
||||||
#: ../data/gnome-shell.desktop.in.in.h:1
|
#: ../data/gnome-shell.desktop.in.in.h:1
|
||||||
msgid "GNOME Shell"
|
msgid "GNOME Shell"
|
||||||
msgstr "GNOME Shell"
|
msgstr "GNOME Shell"
|
||||||
@ -136,71 +128,50 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
||||||
msgid "Always show the 'Log out' menuitem in the user menu."
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
|
||||||
msgid ""
|
|
||||||
"This key overrides the automatic hiding of the 'Log out' menuitem in single-"
|
|
||||||
"user, single-session situations."
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
|
||||||
msgid "Show the week date in the calendar"
|
msgid "Show the week date in the calendar"
|
||||||
msgstr "Vis dato for uken i kalender"
|
msgstr "Vis dato for uken i kalender"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
||||||
msgid "If true, display the ISO week date in the calendar."
|
msgid "If true, display the ISO week date in the calendar."
|
||||||
msgstr "Viser ISO-ukedato i kalenderen hvis «true»."
|
msgstr "Viser ISO-ukedato i kalenderen hvis «true»."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
||||||
msgid "Keybinding to open the application menu"
|
msgid "Keybinding to open the application menu"
|
||||||
msgstr "Tastaturbinding som åpner programmenyen"
|
msgstr "Tastaturbinding som åpner programmenyen"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
||||||
msgid "Keybinding to open the application menu."
|
msgid "Keybinding to open the application menu."
|
||||||
msgstr "Tastaturbinding som åpner programmenyen."
|
msgstr "Tastaturbinding som åpner programmenyen."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
||||||
#, fuzzy
|
|
||||||
msgid "Keybinding to open the \"Show Applications\" view"
|
|
||||||
msgstr "Tastaturbinding som åpner programmenyen"
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
|
||||||
#, fuzzy
|
|
||||||
msgid ""
|
|
||||||
"Keybinding to open the \"Show Applications\" view of the Activities Overview."
|
|
||||||
msgstr "Tastaturbinding som åpner programmenyen."
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
|
||||||
msgid "Keybinding to toggle the visibility of the message tray"
|
msgid "Keybinding to toggle the visibility of the message tray"
|
||||||
msgstr "Tastaturbinding som slår av/på synlighet for meldingstrau"
|
msgstr "Tastaturbinding som slår av/på synlighet for meldingstrau"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
||||||
msgid "Keybinding to toggle the visibility of the message tray."
|
msgid "Keybinding to toggle the visibility of the message tray."
|
||||||
msgstr "Tastaturbinding som slår av/på synlighet for meldingstrauet."
|
msgstr "Tastaturbinding som slår av/på synlighet for meldingstrauet."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
||||||
msgid "Keybinding to toggle the screen recorder"
|
msgid "Keybinding to toggle the screen recorder"
|
||||||
msgstr "Tastaturbinding som slår av/på skjermopptak"
|
msgstr "Tastaturbinding som slår av/på skjermopptak"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
||||||
msgid "Keybinding to start/stop the builtin screen recorder."
|
msgid "Keybinding to start/stop the builtin screen recorder."
|
||||||
msgstr "Tastaturbinding som starter/stopper innebygget opptak av skjerm."
|
msgstr "Tastaturbinding som starter/stopper innebygget opptak av skjerm."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
||||||
msgid "Which keyboard to use"
|
msgid "Which keyboard to use"
|
||||||
msgstr "Tastatur som skal brukes"
|
msgstr "Tastatur som skal brukes"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:26
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
||||||
msgid "The type of keyboard to use."
|
msgid "The type of keyboard to use."
|
||||||
msgstr "Type tastatur som skal brukes."
|
msgstr "Type tastatur som skal brukes."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
||||||
msgid "Framerate used for recording screencasts."
|
msgid "Framerate used for recording screencasts."
|
||||||
msgstr "Bildefrekvens i bruk ved lagring av skjermvideoer."
|
msgstr "Bildefrekvens i bruk ved lagring av skjermvideoer."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:28
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
||||||
msgid ""
|
msgid ""
|
||||||
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
||||||
"screencast recorder in frames-per-second."
|
"screencast recorder in frames-per-second."
|
||||||
@ -208,11 +179,11 @@ msgstr ""
|
|||||||
"Bildefrekvensen i den ferdige skjermvideoen tatt opp med GNOME Shells "
|
"Bildefrekvensen i den ferdige skjermvideoen tatt opp med GNOME Shells "
|
||||||
"skjermvideoopptaker i bilder per sekund."
|
"skjermvideoopptaker i bilder per sekund."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
||||||
msgid "The gstreamer pipeline used to encode the screencast"
|
msgid "The gstreamer pipeline used to encode the screencast"
|
||||||
msgstr "Gstreamer-kommandokø brukt til å kode skjermvideoen"
|
msgstr "Gstreamer-kommandokø brukt til å kode skjermvideoen"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:31
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
||||||
#, fuzzy, no-c-format
|
#, fuzzy, no-c-format
|
||||||
msgid ""
|
msgid ""
|
||||||
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
||||||
@ -229,11 +200,11 @@ msgstr ""
|
|||||||
"Setter GStreamer-rør som brukes til å kode opptak. Den følger syntaksen som "
|
"Setter GStreamer-rør som brukes til å kode opptak. Den følger syntaksen som "
|
||||||
"brukes for gst-launch. Røret må ha en..."
|
"brukes for gst-launch. Røret må ha en..."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:32
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:28
|
||||||
msgid "File extension used for storing the screencast"
|
msgid "File extension used for storing the screencast"
|
||||||
msgstr "Filendelse i bruk ved lagring av skjermvideo"
|
msgstr "Filendelse i bruk ved lagring av skjermvideo"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:33
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
||||||
msgid ""
|
msgid ""
|
||||||
"The filename for recorded screencasts will be a unique filename based on the "
|
"The filename for recorded screencasts will be a unique filename based on the "
|
||||||
"current date, and use this extension. It should be changed when recording to "
|
"current date, and use this extension. It should be changed when recording to "
|
||||||
@ -243,37 +214,6 @@ msgstr ""
|
|||||||
"og bruke denne filendelsen. Den bør endres når du gjør opptak til et nytt "
|
"og bruke denne filendelsen. Den bør endres når du gjør opptak til et nytt "
|
||||||
"oppbevaringsformat."
|
"oppbevaringsformat."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:34
|
|
||||||
msgid "Attach modal dialog to the parent window"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:35
|
|
||||||
msgid ""
|
|
||||||
"This key overrides the key in org.gnome.mutter when running GNOME Shell."
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:36
|
|
||||||
msgid "Arrangement of buttons on the titlebar"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:37
|
|
||||||
msgid ""
|
|
||||||
"This key overrides the key in org.gnome.desktop.wm.preferences when running "
|
|
||||||
"GNOME Shell."
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:38
|
|
||||||
msgid "Enable edge tiling when dropping windows on screen edges"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:39
|
|
||||||
msgid "Workspaces are managed dynamically"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:40
|
|
||||||
msgid "Workspaces only on primary monitor"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ../js/extensionPrefs/main.js:124
|
#: ../js/extensionPrefs/main.js:124
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "There was an error loading the preferences dialog for %s:"
|
msgid "There was an error loading the preferences dialog for %s:"
|
||||||
@ -287,11 +227,11 @@ msgstr "Utvidelse"
|
|||||||
msgid "Select an extension to configure using the combobox above."
|
msgid "Select an extension to configure using the combobox above."
|
||||||
msgstr "Velg en utvidelse som skal konfigureres med komboboksen over."
|
msgstr "Velg en utvidelse som skal konfigureres med komboboksen over."
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:560
|
#: ../js/gdm/loginDialog.js:529
|
||||||
msgid "Session..."
|
msgid "Session..."
|
||||||
msgstr "Økt …"
|
msgstr "Økt …"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:704
|
#: ../js/gdm/loginDialog.js:677
|
||||||
msgctxt "title"
|
msgctxt "title"
|
||||||
msgid "Sign In"
|
msgid "Sign In"
|
||||||
msgstr "Logg inn"
|
msgstr "Logg inn"
|
||||||
@ -299,56 +239,56 @@ msgstr "Logg inn"
|
|||||||
#. translators: this message is shown below the user list on the
|
#. translators: this message is shown below the user list on the
|
||||||
#. login screen. It can be activated to reveal an entry for
|
#. login screen. It can be activated to reveal an entry for
|
||||||
#. manually entering the username.
|
#. manually entering the username.
|
||||||
#: ../js/gdm/loginDialog.js:764
|
#: ../js/gdm/loginDialog.js:736
|
||||||
msgid "Not listed?"
|
msgid "Not listed?"
|
||||||
msgstr "Ikke listet?"
|
msgstr "Ikke listet?"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:906 ../js/ui/components/networkAgent.js:137
|
#: ../js/gdm/loginDialog.js:889 ../js/ui/components/networkAgent.js:137
|
||||||
#: ../js/ui/components/polkitAgent.js:162 ../js/ui/endSessionDialog.js:373
|
#: ../js/ui/components/polkitAgent.js:162 ../js/ui/endSessionDialog.js:373
|
||||||
#: ../js/ui/extensionDownloader.js:195 ../js/ui/shellMountOperation.js:396
|
#: ../js/ui/extensionDownloader.js:195 ../js/ui/shellMountOperation.js:396
|
||||||
#: ../js/ui/status/bluetooth.js:427 ../js/ui/unlockDialog.js:171
|
#: ../js/ui/status/bluetooth.js:427 ../js/ui/unlockDialog.js:166
|
||||||
msgid "Cancel"
|
msgid "Cancel"
|
||||||
msgstr "Avbryt"
|
msgstr "Avbryt"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:911
|
#: ../js/gdm/loginDialog.js:894
|
||||||
msgctxt "button"
|
msgctxt "button"
|
||||||
msgid "Sign In"
|
msgid "Sign In"
|
||||||
msgstr "Logg inn"
|
msgstr "Logg inn"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:1237
|
#: ../js/gdm/loginDialog.js:1215
|
||||||
msgid "Login Window"
|
msgid "Login Window"
|
||||||
msgstr "Innloggingsvindu"
|
msgstr "Innloggingsvindu"
|
||||||
|
|
||||||
#. Translators: accessible name of the power menu in the login screen
|
#. Translators: accessible name of the power menu in the login screen
|
||||||
#: ../js/gdm/powerMenu.js:36
|
#: ../js/gdm/powerMenu.js:35
|
||||||
msgid "Power"
|
msgid "Power"
|
||||||
msgstr "Strøm"
|
msgstr "Strøm"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:93 ../js/ui/userMenu.js:667 ../js/ui/userMenu.js:671
|
#: ../js/gdm/powerMenu.js:89 ../js/ui/userMenu.js:660 ../js/ui/userMenu.js:664
|
||||||
#: ../js/ui/userMenu.js:782
|
#: ../js/ui/userMenu.js:775
|
||||||
msgid "Suspend"
|
msgid "Suspend"
|
||||||
msgstr "Hvilemodus"
|
msgstr "Hvilemodus"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:98
|
#: ../js/gdm/powerMenu.js:94
|
||||||
msgid "Restart"
|
msgid "Restart"
|
||||||
msgstr "Start på nytt"
|
msgstr "Start på nytt"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:103 ../js/ui/userMenu.js:669
|
#: ../js/gdm/powerMenu.js:99 ../js/ui/userMenu.js:662 ../js/ui/userMenu.js:664
|
||||||
#: ../js/ui/userMenu.js:671 ../js/ui/userMenu.js:781
|
#: ../js/ui/userMenu.js:774
|
||||||
msgid "Power Off"
|
msgid "Power Off"
|
||||||
msgstr "Slå av"
|
msgstr "Slå av"
|
||||||
|
|
||||||
#: ../js/gdm/util.js:151
|
#: ../js/gdm/util.js:148
|
||||||
msgid "Authentication error"
|
msgid "Authentication error"
|
||||||
msgstr "Autentiseringsfeil"
|
msgstr "Autentiseringsfeil"
|
||||||
|
|
||||||
#. Translators: this message is shown below the password entry field
|
#. Translators: this message is shown below the password entry field
|
||||||
#. to indicate the user can swipe their finger instead
|
#. to indicate the user can swipe their finger instead
|
||||||
#: ../js/gdm/util.js:268
|
#: ../js/gdm/util.js:265
|
||||||
msgid "(or swipe finger)"
|
msgid "(or swipe finger)"
|
||||||
msgstr "(eller dra finger)"
|
msgstr "(eller dra finger)"
|
||||||
|
|
||||||
#: ../js/gdm/util.js:293
|
#: ../js/gdm/util.js:290
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "(e.g., user or %s)"
|
msgid "(e.g., user or %s)"
|
||||||
msgstr "(f.eks. bruker eller %s)"
|
msgstr "(f.eks. bruker eller %s)"
|
||||||
@ -398,7 +338,7 @@ msgstr "Legg til i favoritter"
|
|||||||
msgid "%s has been added to your favorites."
|
msgid "%s has been added to your favorites."
|
||||||
msgstr "%s ble lagt til i dine favoritter."
|
msgstr "%s ble lagt til i dine favoritter."
|
||||||
|
|
||||||
#: ../js/ui/appFavorites.js:121
|
#: ../js/ui/appFavorites.js:118
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s has been removed from your favorites."
|
msgid "%s has been removed from your favorites."
|
||||||
msgstr "%s ble fjernet fra dine favoritter."
|
msgstr "%s ble fjernet fra dine favoritter."
|
||||||
@ -517,48 +457,48 @@ msgid "S"
|
|||||||
msgstr "Lø"
|
msgstr "Lø"
|
||||||
|
|
||||||
#. Translators: Text to show if there are no events
|
#. Translators: Text to show if there are no events
|
||||||
#: ../js/ui/calendar.js:700
|
#: ../js/ui/calendar.js:699
|
||||||
msgid "Nothing Scheduled"
|
msgid "Nothing Scheduled"
|
||||||
msgstr "Ingenting planlagt"
|
msgstr "Ingenting planlagt"
|
||||||
|
|
||||||
#. Translators: Shown on calendar heading when selected day occurs on current year
|
#. Translators: Shown on calendar heading when selected day occurs on current year
|
||||||
#: ../js/ui/calendar.js:716
|
#: ../js/ui/calendar.js:715
|
||||||
msgctxt "calendar heading"
|
msgctxt "calendar heading"
|
||||||
msgid "%A, %B %d"
|
msgid "%A, %B %d"
|
||||||
msgstr "%A %B %d"
|
msgstr "%A %B %d"
|
||||||
|
|
||||||
#. Translators: Shown on calendar heading when selected day occurs on different year
|
#. Translators: Shown on calendar heading when selected day occurs on different year
|
||||||
#: ../js/ui/calendar.js:719
|
#: ../js/ui/calendar.js:718
|
||||||
msgctxt "calendar heading"
|
msgctxt "calendar heading"
|
||||||
msgid "%A, %B %d, %Y"
|
msgid "%A, %B %d, %Y"
|
||||||
msgstr "%A %B %d, %Y"
|
msgstr "%A %B %d, %Y"
|
||||||
|
|
||||||
#: ../js/ui/calendar.js:729
|
#: ../js/ui/calendar.js:728
|
||||||
msgid "Today"
|
msgid "Today"
|
||||||
msgstr "I dag"
|
msgstr "I dag"
|
||||||
|
|
||||||
#: ../js/ui/calendar.js:733
|
#: ../js/ui/calendar.js:732
|
||||||
msgid "Tomorrow"
|
msgid "Tomorrow"
|
||||||
msgstr "I morgen"
|
msgstr "I morgen"
|
||||||
|
|
||||||
#: ../js/ui/calendar.js:744
|
#: ../js/ui/calendar.js:743
|
||||||
msgid "This week"
|
msgid "This week"
|
||||||
msgstr "Denne uken"
|
msgstr "Denne uken"
|
||||||
|
|
||||||
#: ../js/ui/calendar.js:752
|
#: ../js/ui/calendar.js:751
|
||||||
msgid "Next week"
|
msgid "Next week"
|
||||||
msgstr "Neste uke"
|
msgstr "Neste uke"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:295
|
#: ../js/ui/components/autorunManager.js:297
|
||||||
msgid "Removable Devices"
|
msgid "Removable Devices"
|
||||||
msgstr "Avtagbare enheter"
|
msgstr "Avtagbare enheter"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:591
|
#: ../js/ui/components/autorunManager.js:594
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Open with %s"
|
msgid "Open with %s"
|
||||||
msgstr "Åpne med %s"
|
msgstr "Åpne med %s"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:617
|
#: ../js/ui/components/autorunManager.js:620
|
||||||
msgid "Eject"
|
msgid "Eject"
|
||||||
msgstr "Løs ut"
|
msgstr "Løs ut"
|
||||||
|
|
||||||
@ -712,42 +652,38 @@ msgstr "Fjern demping"
|
|||||||
msgid "Mute"
|
msgid "Mute"
|
||||||
msgstr "Demp"
|
msgstr "Demp"
|
||||||
|
|
||||||
#. Translators: this is a time format string followed by the word "Yesterday". i.e. "14:30 on Yesterday"
|
#. Translators: this is a time format string followed by a date.
|
||||||
#: ../js/ui/components/telepathyClient.js:945
|
#. If applicable, replace %X with a strftime format valid for your
|
||||||
|
#. locale, without seconds.
|
||||||
|
#: ../js/ui/components/telepathyClient.js:948
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "<b>%H:%M</b> on Yesterday"
|
msgid "Sent at <b>%X</b> on <b>%A</b>"
|
||||||
msgstr "<b>%H.%M</b> i går"
|
msgstr "Sendt <b>%X</b> på <b>%A</b>"
|
||||||
|
|
||||||
#. Translators: this is a time format string followed by a week day name. i.e. "14:30 on Monday
|
#. Translators: this is a time format in the style of "Wednesday, May 25",
|
||||||
#: ../js/ui/components/telepathyClient.js:951
|
#. shown when you get a chat message in the same year.
|
||||||
|
#: ../js/ui/components/telepathyClient.js:954
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "<b>%H:%M</b> on <b>%A</b>"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>"
|
||||||
msgstr "<b>%H.%M</b> på <b>%A</b>"
|
msgstr "Sendt <b>%A</b>, <b>%B %d</b>"
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "14:30 on Wednesday, May 25",
|
#. Translators: this is a time format in the style of "Wednesday, May 25, 2012",
|
||||||
#. shown when you get a chat message in the same year
|
#. shown when you get a chat message in a different year.
|
||||||
#: ../js/ui/components/telepathyClient.js:957
|
#: ../js/ui/components/telepathyClient.js:959
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "<b>%H:%M</b> on <b>%A</b>, <b>%B</b> <b>%d</b>"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>, %Y"
|
||||||
msgstr "<b>%H.%M</b>, <b>%A</b>, <b>%B</b> <b>%d</b>"
|
msgstr "Sendt <b>%A</b>, <b>%B %d</b>, %Y"
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "14:30 on Wednesday, May 25, 2012",
|
|
||||||
#. shown when you get a chat message in a different year
|
|
||||||
#: ../js/ui/components/telepathyClient.js:962
|
|
||||||
#, no-c-format
|
|
||||||
msgid "<b>%H:%M</b> on <b>%A</b>, <b>%B</b> <b>%d</b>, %Y"
|
|
||||||
msgstr "<b>%H.%M</b>, <b>%A</b>, <b>%B</b> <b>%d</b>, %Y"
|
|
||||||
|
|
||||||
#. Translators: this is the other person changing their old IM name to their new
|
#. Translators: this is the other person changing their old IM name to their new
|
||||||
#. IM name.
|
#. IM name.
|
||||||
#: ../js/ui/components/telepathyClient.js:990
|
#: ../js/ui/components/telepathyClient.js:988
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is now known as %s"
|
msgid "%s is now known as %s"
|
||||||
msgstr "%s er nå kjent som %s"
|
msgstr "%s er nå kjent som %s"
|
||||||
|
|
||||||
#. translators: argument is a room name like
|
#. translators: argument is a room name like
|
||||||
#. * room@jabber.org for example.
|
#. * room@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1089
|
#: ../js/ui/components/telepathyClient.js:1088
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Invitation to %s"
|
msgid "Invitation to %s"
|
||||||
msgstr "Invitasjon til %s"
|
msgstr "Invitasjon til %s"
|
||||||
@ -755,42 +691,42 @@ msgstr "Invitasjon til %s"
|
|||||||
#. translators: first argument is the name of a contact and the second
|
#. translators: first argument is the name of a contact and the second
|
||||||
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
||||||
#. * for example.
|
#. * for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1097
|
#: ../js/ui/components/telepathyClient.js:1096
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is inviting you to join %s"
|
msgid "%s is inviting you to join %s"
|
||||||
msgstr "%s inviterer deg til å bli med i %s"
|
msgstr "%s inviterer deg til å bli med i %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1099
|
#: ../js/ui/components/telepathyClient.js:1098
|
||||||
#: ../js/ui/components/telepathyClient.js:1178
|
#: ../js/ui/components/telepathyClient.js:1177
|
||||||
#: ../js/ui/components/telepathyClient.js:1241
|
#: ../js/ui/components/telepathyClient.js:1240
|
||||||
msgid "Decline"
|
msgid "Decline"
|
||||||
msgstr "Avslå"
|
msgstr "Avslå"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1100
|
#: ../js/ui/components/telepathyClient.js:1099
|
||||||
#: ../js/ui/components/telepathyClient.js:1179
|
#: ../js/ui/components/telepathyClient.js:1178
|
||||||
#: ../js/ui/components/telepathyClient.js:1242
|
#: ../js/ui/components/telepathyClient.js:1241
|
||||||
msgid "Accept"
|
msgid "Accept"
|
||||||
msgstr "Godta"
|
msgstr "Godta"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1130
|
#: ../js/ui/components/telepathyClient.js:1129
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Video call from %s"
|
msgid "Video call from %s"
|
||||||
msgstr "Videosamtale fra %s"
|
msgstr "Videosamtale fra %s"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1133
|
#: ../js/ui/components/telepathyClient.js:1132
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Call from %s"
|
msgid "Call from %s"
|
||||||
msgstr "Samtale fra %s"
|
msgstr "Samtale fra %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1138
|
#: ../js/ui/components/telepathyClient.js:1137
|
||||||
#: ../js/ui/status/bluetooth.js:346
|
#: ../js/ui/status/bluetooth.js:346
|
||||||
msgid "Reject"
|
msgid "Reject"
|
||||||
msgstr "Avvis"
|
msgstr "Avvis"
|
||||||
|
|
||||||
#. translators: this is a button label (verb), not a noun
|
#. translators: this is a button label (verb), not a noun
|
||||||
#: ../js/ui/components/telepathyClient.js:1140
|
#: ../js/ui/components/telepathyClient.js:1139
|
||||||
msgid "Answer"
|
msgid "Answer"
|
||||||
msgstr "Svar"
|
msgstr "Svar"
|
||||||
|
|
||||||
@ -799,110 +735,110 @@ msgstr "Svar"
|
|||||||
#. * file name. The string will be something
|
#. * file name. The string will be something
|
||||||
#. * like: "Alice is sending you test.ogg"
|
#. * like: "Alice is sending you test.ogg"
|
||||||
#.
|
#.
|
||||||
#: ../js/ui/components/telepathyClient.js:1172
|
#: ../js/ui/components/telepathyClient.js:1171
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is sending you %s"
|
msgid "%s is sending you %s"
|
||||||
msgstr "%s sender deg %s"
|
msgstr "%s sender deg %s"
|
||||||
|
|
||||||
#. To translators: The parameter is the contact's alias
|
#. To translators: The parameter is the contact's alias
|
||||||
#: ../js/ui/components/telepathyClient.js:1207
|
#: ../js/ui/components/telepathyClient.js:1206
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s would like permission to see when you are online"
|
msgid "%s would like permission to see when you are online"
|
||||||
msgstr "%s vil ha rettigheter til å se når du er tilkoblet"
|
msgstr "%s vil ha rettigheter til å se når du er tilkoblet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1299
|
#: ../js/ui/components/telepathyClient.js:1298
|
||||||
msgid "Network error"
|
msgid "Network error"
|
||||||
msgstr "Nettverksfeil"
|
msgstr "Nettverksfeil"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1301
|
#: ../js/ui/components/telepathyClient.js:1300
|
||||||
msgid "Authentication failed"
|
msgid "Authentication failed"
|
||||||
msgstr "Autentisering feilet"
|
msgstr "Autentisering feilet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1303
|
#: ../js/ui/components/telepathyClient.js:1302
|
||||||
msgid "Encryption error"
|
msgid "Encryption error"
|
||||||
msgstr "Feil ved kryptering"
|
msgstr "Feil ved kryptering"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1305
|
#: ../js/ui/components/telepathyClient.js:1304
|
||||||
msgid "Certificate not provided"
|
msgid "Certificate not provided"
|
||||||
msgstr "Sertifikat ikke oppgitt"
|
msgstr "Sertifikat ikke oppgitt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1307
|
#: ../js/ui/components/telepathyClient.js:1306
|
||||||
msgid "Certificate untrusted"
|
msgid "Certificate untrusted"
|
||||||
msgstr "Stoler ikke på sertifikatet"
|
msgstr "Stoler ikke på sertifikatet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1309
|
#: ../js/ui/components/telepathyClient.js:1308
|
||||||
msgid "Certificate expired"
|
msgid "Certificate expired"
|
||||||
msgstr "Sertifikatet er utløpt"
|
msgstr "Sertifikatet er utløpt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1311
|
#: ../js/ui/components/telepathyClient.js:1310
|
||||||
msgid "Certificate not activated"
|
msgid "Certificate not activated"
|
||||||
msgstr "Sertifikatet er ikke aktivert"
|
msgstr "Sertifikatet er ikke aktivert"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1313
|
#: ../js/ui/components/telepathyClient.js:1312
|
||||||
msgid "Certificate hostname mismatch"
|
msgid "Certificate hostname mismatch"
|
||||||
msgstr "Feil vertsnavn for sertifikat"
|
msgstr "Feil vertsnavn for sertifikat"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1315
|
#: ../js/ui/components/telepathyClient.js:1314
|
||||||
msgid "Certificate fingerprint mismatch"
|
msgid "Certificate fingerprint mismatch"
|
||||||
msgstr "Feil fingeravtrykk for sertifikat"
|
msgstr "Feil fingeravtrykk for sertifikat"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1317
|
#: ../js/ui/components/telepathyClient.js:1316
|
||||||
msgid "Certificate self-signed"
|
msgid "Certificate self-signed"
|
||||||
msgstr "Sertifikatet er selvsignert"
|
msgstr "Sertifikatet er selvsignert"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1319
|
#: ../js/ui/components/telepathyClient.js:1318
|
||||||
msgid "Status is set to offline"
|
msgid "Status is set to offline"
|
||||||
msgstr "Status er satt til frakoblet"
|
msgstr "Status er satt til frakoblet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1321
|
#: ../js/ui/components/telepathyClient.js:1320
|
||||||
msgid "Encryption is not available"
|
msgid "Encryption is not available"
|
||||||
msgstr "Kryptering er ikke tilgjengelig"
|
msgstr "Kryptering er ikke tilgjengelig"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1323
|
#: ../js/ui/components/telepathyClient.js:1322
|
||||||
msgid "Certificate is invalid"
|
msgid "Certificate is invalid"
|
||||||
msgstr "Sertifikatet er ugyldig"
|
msgstr "Sertifikatet er ugyldig"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1325
|
#: ../js/ui/components/telepathyClient.js:1324
|
||||||
msgid "Connection has been refused"
|
msgid "Connection has been refused"
|
||||||
msgstr "Tilkobling ble nektet"
|
msgstr "Tilkobling ble nektet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1327
|
#: ../js/ui/components/telepathyClient.js:1326
|
||||||
msgid "Connection can't be established"
|
msgid "Connection can't be established"
|
||||||
msgstr "Tilkobling kan ikke etableres"
|
msgstr "Tilkobling kan ikke etableres"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1329
|
#: ../js/ui/components/telepathyClient.js:1328
|
||||||
msgid "Connection has been lost"
|
msgid "Connection has been lost"
|
||||||
msgstr "Tilkobling tapt"
|
msgstr "Tilkobling tapt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1331
|
#: ../js/ui/components/telepathyClient.js:1330
|
||||||
msgid "This account is already connected to the server"
|
msgid "This account is already connected to the server"
|
||||||
msgstr "Denne kontoen er allerede koblet til tjeneren"
|
msgstr "Denne kontoen er allerede koblet til tjeneren"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1333
|
#: ../js/ui/components/telepathyClient.js:1332
|
||||||
msgid ""
|
msgid ""
|
||||||
"Connection has been replaced by a new connection using the same resource"
|
"Connection has been replaced by a new connection using the same resource"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Tilkoblingen har blitt erstattet av en ny tilkobling som bruker samme ressurs"
|
"Tilkoblingen har blitt erstattet av en ny tilkobling som bruker samme ressurs"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1335
|
#: ../js/ui/components/telepathyClient.js:1334
|
||||||
msgid "The account already exists on the server"
|
msgid "The account already exists on the server"
|
||||||
msgstr "Kontoen eksisterer allerede på tjeneren"
|
msgstr "Kontoen eksisterer allerede på tjeneren"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1337
|
#: ../js/ui/components/telepathyClient.js:1336
|
||||||
msgid "Server is currently too busy to handle the connection"
|
msgid "Server is currently too busy to handle the connection"
|
||||||
msgstr "Tjener er for opptatt til å håndtere tilkoblingen"
|
msgstr "Tjener er for opptatt til å håndtere tilkoblingen"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1339
|
#: ../js/ui/components/telepathyClient.js:1338
|
||||||
msgid "Certificate has been revoked"
|
msgid "Certificate has been revoked"
|
||||||
msgstr "Sertifikatet er tilbaketrukket"
|
msgstr "Sertifikatet er tilbaketrukket"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1341
|
#: ../js/ui/components/telepathyClient.js:1340
|
||||||
msgid ""
|
msgid ""
|
||||||
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Sertifikatet bruker en usikker sifferalgoritme eller er krytografisk svakt"
|
"Sertifikatet bruker en usikker sifferalgoritme eller er krytografisk svakt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1343
|
#: ../js/ui/components/telepathyClient.js:1342
|
||||||
msgid ""
|
msgid ""
|
||||||
"The length of the server certificate, or the depth of the server certificate "
|
"The length of the server certificate, or the depth of the server certificate "
|
||||||
"chain, exceed the limits imposed by the cryptography library"
|
"chain, exceed the limits imposed by the cryptography library"
|
||||||
@ -910,26 +846,26 @@ msgstr ""
|
|||||||
"Lengden eller dybden på tjenersertifikatet oversteg grensen som er satt i "
|
"Lengden eller dybden på tjenersertifikatet oversteg grensen som er satt i "
|
||||||
"kryptografibiblioteket"
|
"kryptografibiblioteket"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1345
|
#: ../js/ui/components/telepathyClient.js:1344
|
||||||
msgid "Internal error"
|
msgid "Internal error"
|
||||||
msgstr "Intern feil"
|
msgstr "Intern feil"
|
||||||
|
|
||||||
#. translators: argument is the account name, like
|
#. translators: argument is the account name, like
|
||||||
#. * name@jabber.org for example.
|
#. * name@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1355
|
#: ../js/ui/components/telepathyClient.js:1354
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Connection to %s failed"
|
msgid "Connection to %s failed"
|
||||||
msgstr "Tilkobling til %s feilet"
|
msgstr "Tilkobling til %s feilet"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1364
|
#: ../js/ui/components/telepathyClient.js:1363
|
||||||
msgid "Reconnect"
|
msgid "Reconnect"
|
||||||
msgstr "Koble til på nytt"
|
msgstr "Koble til på nytt"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1365
|
#: ../js/ui/components/telepathyClient.js:1364
|
||||||
msgid "Edit account"
|
msgid "Edit account"
|
||||||
msgstr "Rediger konto"
|
msgstr "Rediger konto"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1410
|
#: ../js/ui/components/telepathyClient.js:1409
|
||||||
msgid "Unknown reason"
|
msgid "Unknown reason"
|
||||||
msgstr "Ukjent årsak"
|
msgstr "Ukjent årsak"
|
||||||
|
|
||||||
@ -948,7 +884,7 @@ msgstr "Åpne kalender"
|
|||||||
#. Translators: This is the date format to use when the calendar popup is
|
#. Translators: This is the date format to use when the calendar popup is
|
||||||
#. * shown - it is shown just below the time in the shell (e.g. "Tue 9:29 AM").
|
#. * shown - it is shown just below the time in the shell (e.g. "Tue 9:29 AM").
|
||||||
#.
|
#.
|
||||||
#: ../js/ui/dateMenu.js:201
|
#: ../js/ui/dateMenu.js:190
|
||||||
msgid "%A %B %e, %Y"
|
msgid "%A %B %e, %Y"
|
||||||
msgstr "%a %e %B, %Y"
|
msgstr "%a %e %B, %Y"
|
||||||
|
|
||||||
@ -1053,11 +989,11 @@ msgstr "Installer"
|
|||||||
msgid "Download and install '%s' from extensions.gnome.org?"
|
msgid "Download and install '%s' from extensions.gnome.org?"
|
||||||
msgstr "Last ned og installer «%s» fra extensions.gnome.org?"
|
msgstr "Last ned og installer «%s» fra extensions.gnome.org?"
|
||||||
|
|
||||||
#: ../js/ui/keyboard.js:308
|
#: ../js/ui/keyboard.js:337
|
||||||
msgid "tray"
|
msgid "tray"
|
||||||
msgstr "varslingsområde"
|
msgstr "varslingsområde"
|
||||||
|
|
||||||
#: ../js/ui/keyboard.js:555 ../js/ui/status/keyboard.js:195
|
#: ../js/ui/keyboard.js:584 ../js/ui/status/keyboard.js:195
|
||||||
#: ../js/ui/status/power.js:205
|
#: ../js/ui/status/power.js:205
|
||||||
msgid "Keyboard"
|
msgid "Keyboard"
|
||||||
msgstr "Tastatur"
|
msgstr "Tastatur"
|
||||||
@ -1110,32 +1046,32 @@ msgstr "Vis kildekode"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Nettside"
|
msgstr "Nettside"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1088
|
#: ../js/ui/messageTray.js:1081
|
||||||
msgid "Open"
|
msgid "Open"
|
||||||
msgstr "Åpne"
|
msgstr "Åpne"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1095
|
#: ../js/ui/messageTray.js:1088
|
||||||
msgid "Remove"
|
msgid "Remove"
|
||||||
msgstr "Fjern"
|
msgstr "Fjern"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1539
|
#: ../js/ui/messageTray.js:1540
|
||||||
msgid "Message Tray"
|
msgid "Message Tray"
|
||||||
msgstr "Meldingstrau"
|
msgstr "Meldingstrau"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:2563
|
#: ../js/ui/messageTray.js:2547
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Systeminformasjon"
|
msgstr "Systeminformasjon"
|
||||||
|
|
||||||
#: ../js/ui/notificationDaemon.js:504 ../src/shell-app.c:374
|
#: ../js/ui/notificationDaemon.js:506 ../src/shell-app.c:373
|
||||||
msgctxt "program"
|
msgctxt "program"
|
||||||
msgid "Unknown"
|
msgid "Unknown"
|
||||||
msgstr "Ukjent"
|
msgstr "Ukjent"
|
||||||
|
|
||||||
#: ../js/ui/overview.js:89
|
#: ../js/ui/overview.js:82
|
||||||
msgid "Undo"
|
msgid "Undo"
|
||||||
msgstr "Angre"
|
msgstr "Angre"
|
||||||
|
|
||||||
#: ../js/ui/overview.js:133
|
#: ../js/ui/overview.js:127
|
||||||
msgid "Overview"
|
msgid "Overview"
|
||||||
msgstr "Oversikt"
|
msgstr "Oversikt"
|
||||||
|
|
||||||
@ -1143,27 +1079,27 @@ msgstr "Oversikt"
|
|||||||
#. in the search entry when no search is
|
#. in the search entry when no search is
|
||||||
#. active; it should not exceed ~30
|
#. active; it should not exceed ~30
|
||||||
#. characters.
|
#. characters.
|
||||||
#: ../js/ui/overview.js:207
|
#: ../js/ui/overview.js:201
|
||||||
msgid "Type to search..."
|
msgid "Type to search..."
|
||||||
msgstr "Skriv for å søke …"
|
msgstr "Skriv for å søke …"
|
||||||
|
|
||||||
#. Translators: this is the name of the dock/favorites area on
|
#. Translators: this is the name of the dock/favorites area on
|
||||||
#. the left of the overview
|
#. the left of the overview
|
||||||
#: ../js/ui/overview.js:228
|
#: ../js/ui/overview.js:222
|
||||||
msgid "Dash"
|
msgid "Dash"
|
||||||
msgstr "Favoritter"
|
msgstr "Favoritter"
|
||||||
|
|
||||||
#: ../js/ui/panel.js:581
|
#: ../js/ui/panel.js:567
|
||||||
msgid "Quit"
|
msgid "Quit"
|
||||||
msgstr "Avslutt"
|
msgstr "Avslutt"
|
||||||
|
|
||||||
#. Translators: If there is no suitable word for "Activities"
|
#. Translators: If there is no suitable word for "Activities"
|
||||||
#. in your language, you can use the word for "Overview".
|
#. in your language, you can use the word for "Overview".
|
||||||
#: ../js/ui/panel.js:613
|
#: ../js/ui/panel.js:599
|
||||||
msgid "Activities"
|
msgid "Activities"
|
||||||
msgstr "Aktiviteter"
|
msgstr "Aktiviteter"
|
||||||
|
|
||||||
#: ../js/ui/panel.js:980
|
#: ../js/ui/panel.js:965
|
||||||
msgid "Top Bar"
|
msgid "Top Bar"
|
||||||
msgstr "Topp-panel"
|
msgstr "Topp-panel"
|
||||||
|
|
||||||
@ -1177,27 +1113,23 @@ msgid "toggle-switch-us"
|
|||||||
msgstr "toggle-switch-intl"
|
msgstr "toggle-switch-intl"
|
||||||
|
|
||||||
#: ../js/ui/runDialog.js:205
|
#: ../js/ui/runDialog.js:205
|
||||||
msgid "Enter a Command"
|
msgid "Please enter a command:"
|
||||||
msgstr "Oppgi en kommando"
|
msgstr "Oppgi en kommando:"
|
||||||
|
|
||||||
#: ../js/ui/runDialog.js:241
|
|
||||||
msgid "Close"
|
|
||||||
msgstr "Lukk"
|
|
||||||
|
|
||||||
#. Translators: This is a time format for a date in
|
#. Translators: This is a time format for a date in
|
||||||
#. long format
|
#. long format
|
||||||
#: ../js/ui/screenShield.js:80
|
#: ../js/ui/screenShield.js:79
|
||||||
msgid "%A, %B %d"
|
msgid "%A, %B %d"
|
||||||
msgstr "%A, %B %d"
|
msgstr "%A, %B %d"
|
||||||
|
|
||||||
#: ../js/ui/screenShield.js:144
|
#: ../js/ui/screenShield.js:143
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%d new message"
|
msgid "%d new message"
|
||||||
msgid_plural "%d new messages"
|
msgid_plural "%d new messages"
|
||||||
msgstr[0] "%d ny melding"
|
msgstr[0] "%d ny melding"
|
||||||
msgstr[1] "%d nye meldinger"
|
msgstr[1] "%d nye meldinger"
|
||||||
|
|
||||||
#: ../js/ui/screenShield.js:146
|
#: ../js/ui/screenShield.js:145
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%d new notification"
|
msgid "%d new notification"
|
||||||
msgid_plural "%d new notifications"
|
msgid_plural "%d new notifications"
|
||||||
@ -1236,7 +1168,7 @@ msgstr "Passord"
|
|||||||
msgid "Remember Password"
|
msgid "Remember Password"
|
||||||
msgstr "Husk passord"
|
msgstr "Husk passord"
|
||||||
|
|
||||||
#: ../js/ui/shellMountOperation.js:400 ../js/ui/unlockDialog.js:174
|
#: ../js/ui/shellMountOperation.js:400 ../js/ui/unlockDialog.js:169
|
||||||
msgid "Unlock"
|
msgid "Unlock"
|
||||||
msgstr "Lås opp"
|
msgstr "Lås opp"
|
||||||
|
|
||||||
@ -1291,7 +1223,7 @@ msgstr "Stor tekst"
|
|||||||
#: ../js/ui/status/bluetooth.js:27 ../js/ui/status/bluetooth.js:31
|
#: ../js/ui/status/bluetooth.js:27 ../js/ui/status/bluetooth.js:31
|
||||||
#: ../js/ui/status/bluetooth.js:251 ../js/ui/status/bluetooth.js:304
|
#: ../js/ui/status/bluetooth.js:251 ../js/ui/status/bluetooth.js:304
|
||||||
#: ../js/ui/status/bluetooth.js:335 ../js/ui/status/bluetooth.js:371
|
#: ../js/ui/status/bluetooth.js:335 ../js/ui/status/bluetooth.js:371
|
||||||
#: ../js/ui/status/bluetooth.js:400 ../js/ui/status/network.js:873
|
#: ../js/ui/status/bluetooth.js:400 ../js/ui/status/network.js:867
|
||||||
msgid "Bluetooth"
|
msgid "Bluetooth"
|
||||||
msgstr "Bluetooth"
|
msgstr "Bluetooth"
|
||||||
|
|
||||||
@ -1320,12 +1252,12 @@ msgstr "maskinvare slått av"
|
|||||||
msgid "Connection"
|
msgid "Connection"
|
||||||
msgstr "Tilkobling"
|
msgstr "Tilkobling"
|
||||||
|
|
||||||
#: ../js/ui/status/bluetooth.js:207 ../js/ui/status/network.js:475
|
#: ../js/ui/status/bluetooth.js:207 ../js/ui/status/network.js:458
|
||||||
msgid "disconnecting..."
|
msgid "disconnecting..."
|
||||||
msgstr "kobler fra …"
|
msgstr "kobler fra …"
|
||||||
|
|
||||||
#: ../js/ui/status/bluetooth.js:220 ../js/ui/status/network.js:481
|
#: ../js/ui/status/bluetooth.js:220 ../js/ui/status/network.js:464
|
||||||
#: ../js/ui/status/network.js:1507
|
#: ../js/ui/status/network.js:934
|
||||||
msgid "connecting..."
|
msgid "connecting..."
|
||||||
msgstr "kobler til …"
|
msgstr "kobler til …"
|
||||||
|
|
||||||
@ -1435,106 +1367,109 @@ msgstr "slått av"
|
|||||||
|
|
||||||
#. Translators: this is for network devices that are physically present but are not
|
#. Translators: this is for network devices that are physically present but are not
|
||||||
#. under NetworkManager's control (and thus cannot be used in the menu)
|
#. under NetworkManager's control (and thus cannot be used in the menu)
|
||||||
#: ../js/ui/status/network.js:473
|
#: ../js/ui/status/network.js:456
|
||||||
msgid "unmanaged"
|
msgid "unmanaged"
|
||||||
msgstr "ikke håndtert"
|
msgstr "ikke håndtert"
|
||||||
|
|
||||||
#. Translators: this is for network connections that require some kind of key or password
|
#. Translators: this is for network connections that require some kind of key or password
|
||||||
#: ../js/ui/status/network.js:484 ../js/ui/status/network.js:1510
|
#: ../js/ui/status/network.js:467 ../js/ui/status/network.js:937
|
||||||
msgid "authentication required"
|
msgid "authentication required"
|
||||||
msgstr "autentisering kreves"
|
msgstr "autentisering kreves"
|
||||||
|
|
||||||
#. Translators: this is for devices that require some kind of firmware or kernel
|
#. Translators: this is for devices that require some kind of firmware or kernel
|
||||||
#. module, which is missing
|
#. module, which is missing
|
||||||
#: ../js/ui/status/network.js:494
|
#: ../js/ui/status/network.js:477
|
||||||
msgid "firmware missing"
|
msgid "firmware missing"
|
||||||
msgstr "fastvare mangler"
|
msgstr "fastvare mangler"
|
||||||
|
|
||||||
#. Translators: this is for wired network devices that are physically disconnected
|
#. Translators: this is for wired network devices that are physically disconnected
|
||||||
#: ../js/ui/status/network.js:501
|
#: ../js/ui/status/network.js:484
|
||||||
msgid "cable unplugged"
|
msgid "cable unplugged"
|
||||||
msgstr "kabel koblet fra"
|
msgstr "kabel koblet fra"
|
||||||
|
|
||||||
#. Translators: this is for a network device that cannot be activated (for example it
|
#. Translators: this is for a network device that cannot be activated (for example it
|
||||||
#. is disabled by rfkill, or it has no coverage
|
#. is disabled by rfkill, or it has no coverage
|
||||||
#: ../js/ui/status/network.js:506
|
#: ../js/ui/status/network.js:489
|
||||||
msgid "unavailable"
|
msgid "unavailable"
|
||||||
msgstr "ikke tilgjengelig"
|
msgstr "ikke tilgjengelig"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:508 ../js/ui/status/network.js:1512
|
#: ../js/ui/status/network.js:491 ../js/ui/status/network.js:939
|
||||||
msgid "connection failed"
|
msgid "connection failed"
|
||||||
msgstr "tilkobling feilet"
|
msgstr "tilkobling feilet"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:560 ../js/ui/status/network.js:1446
|
#: ../js/ui/status/network.js:552 ../js/ui/status/network.js:1529
|
||||||
#: ../js/ui/status/network.js:1588
|
|
||||||
msgid "More..."
|
msgid "More..."
|
||||||
msgstr "Mer …"
|
msgstr "Mer …"
|
||||||
|
|
||||||
#. TRANSLATORS: this is the indication that a connection for another logged in user is active,
|
#. TRANSLATORS: this is the indication that a connection for another logged in user is active,
|
||||||
#. and we cannot access its settings (including the name)
|
#. and we cannot access its settings (including the name)
|
||||||
#: ../js/ui/status/network.js:596 ../js/ui/status/network.js:1376
|
#: ../js/ui/status/network.js:588 ../js/ui/status/network.js:1459
|
||||||
msgid "Connected (private)"
|
msgid "Connected (private)"
|
||||||
msgstr "Tilkoblet (privat)"
|
msgstr "Tilkoblet (privat)"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:669
|
#: ../js/ui/status/network.js:663
|
||||||
msgid "Auto Ethernet"
|
msgid "Auto Ethernet"
|
||||||
msgstr "Automatisk Ethernet"
|
msgstr "Automatisk Ethernet"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:727
|
#: ../js/ui/status/network.js:721
|
||||||
msgid "Auto broadband"
|
msgid "Auto broadband"
|
||||||
msgstr "Automatisk bredbånd"
|
msgstr "Automatisk bredbånd"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:730
|
#: ../js/ui/status/network.js:724
|
||||||
msgid "Auto dial-up"
|
msgid "Auto dial-up"
|
||||||
msgstr "Automatisk oppringt"
|
msgstr "Automatisk oppringt"
|
||||||
|
|
||||||
#. TRANSLATORS: this the automatic wireless connection name (including the network name)
|
#. TRANSLATORS: this the automatic wireless connection name (including the network name)
|
||||||
#: ../js/ui/status/network.js:859 ../js/ui/status/network.js:1393
|
#: ../js/ui/status/network.js:853 ../js/ui/status/network.js:1476
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Auto %s"
|
msgid "Auto %s"
|
||||||
msgstr "Automatisk %s"
|
msgstr "Automatisk %s"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:861
|
#: ../js/ui/status/network.js:855
|
||||||
msgid "Auto bluetooth"
|
msgid "Auto bluetooth"
|
||||||
msgstr "Automatisk Bluetooth"
|
msgstr "Automatisk Bluetooth"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1395
|
#: ../js/ui/status/network.js:1478
|
||||||
msgid "Auto wireless"
|
msgid "Auto wireless"
|
||||||
msgstr "Automatisk trådløst"
|
msgstr "Automatisk trådløst"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1637
|
#: ../js/ui/status/network.js:1575
|
||||||
msgid "Enable networking"
|
msgid "Enable networking"
|
||||||
msgstr "Slå på nettverk"
|
msgstr "Slå på nettverk"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1659
|
#: ../js/ui/status/network.js:1597
|
||||||
msgid "Wired"
|
msgid "Wired"
|
||||||
msgstr "Kablet"
|
msgstr "Kablet"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1670
|
#: ../js/ui/status/network.js:1608
|
||||||
msgid "Wireless"
|
msgid "Wireless"
|
||||||
msgstr "Trådløst"
|
msgstr "Trådløst"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1680
|
#: ../js/ui/status/network.js:1618
|
||||||
msgid "Mobile broadband"
|
msgid "Mobile broadband"
|
||||||
msgstr "Mobilt bredbånd"
|
msgstr "Mobilt bredbånd"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1691
|
#: ../js/ui/status/network.js:1628
|
||||||
|
msgid "VPN Connections"
|
||||||
|
msgstr "VPN-tilkoblinger"
|
||||||
|
|
||||||
|
#: ../js/ui/status/network.js:1635
|
||||||
msgid "Network Settings"
|
msgid "Network Settings"
|
||||||
msgstr "Innstillinger for nettverk"
|
msgstr "Innstillinger for nettverk"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1735
|
#: ../js/ui/status/network.js:1679
|
||||||
msgid "Network Manager"
|
msgid "Network Manager"
|
||||||
msgstr "Nettverkshåndtering"
|
msgstr "Nettverkshåndtering"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1809
|
#: ../js/ui/status/network.js:1769
|
||||||
msgid "Connection failed"
|
msgid "Connection failed"
|
||||||
msgstr "Tilkobling feilet"
|
msgstr "Tilkobling feilet"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:1810
|
#: ../js/ui/status/network.js:1770
|
||||||
msgid "Activation of network connection failed"
|
msgid "Activation of network connection failed"
|
||||||
msgstr "Aktivering av nettverkstilkobling feilet"
|
msgstr "Aktivering av nettverkstilkobling feilet"
|
||||||
|
|
||||||
#: ../js/ui/status/network.js:2108
|
#: ../js/ui/status/network.js:2065
|
||||||
msgid "Networking is disabled"
|
msgid "Networking is disabled"
|
||||||
msgstr "Nettverk er slått av"
|
msgstr "Nettverk er slått av"
|
||||||
|
|
||||||
@ -1644,63 +1579,63 @@ msgstr "Volum"
|
|||||||
msgid "Microphone"
|
msgid "Microphone"
|
||||||
msgstr "Mikrofon"
|
msgstr "Mikrofon"
|
||||||
|
|
||||||
#: ../js/ui/unlockDialog.js:181
|
#: ../js/ui/unlockDialog.js:176
|
||||||
msgid "Log in as another user"
|
msgid "Log in as another user"
|
||||||
msgstr "Logg inn som en annen bruker"
|
msgstr "Logg inn som en annen bruker"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:176
|
#: ../js/ui/userMenu.js:180
|
||||||
msgid "Available"
|
msgid "Available"
|
||||||
msgstr "Tilgjengelig"
|
msgstr "Tilgjengelig"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:179
|
#: ../js/ui/userMenu.js:183
|
||||||
msgid "Busy"
|
msgid "Busy"
|
||||||
msgstr "Opptatt"
|
msgstr "Opptatt"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:182
|
#: ../js/ui/userMenu.js:186
|
||||||
msgid "Invisible"
|
msgid "Invisible"
|
||||||
msgstr "Usynlig"
|
msgstr "Usynlig"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:185
|
#: ../js/ui/userMenu.js:189
|
||||||
msgid "Away"
|
msgid "Away"
|
||||||
msgstr "Borte"
|
msgstr "Borte"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:188
|
#: ../js/ui/userMenu.js:192
|
||||||
msgid "Idle"
|
msgid "Idle"
|
||||||
msgstr "Ledig"
|
msgstr "Ledig"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:191
|
#: ../js/ui/userMenu.js:195
|
||||||
msgid "Offline"
|
msgid "Unavailable"
|
||||||
msgstr "Frakoblet"
|
msgstr "Ikke tilgjengelig"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:747
|
#: ../js/ui/userMenu.js:740
|
||||||
msgid "Notifications"
|
msgid "Notifications"
|
||||||
msgstr "Varslinger"
|
msgstr "Varslinger"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:755
|
#: ../js/ui/userMenu.js:748
|
||||||
msgid "System Settings"
|
msgid "System Settings"
|
||||||
msgstr "Systeminnstillinger"
|
msgstr "Systeminnstillinger"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:763
|
#: ../js/ui/userMenu.js:756
|
||||||
msgid "Switch User"
|
msgid "Switch User"
|
||||||
msgstr "Bytt bruker"
|
msgstr "Bytt bruker"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:768
|
#: ../js/ui/userMenu.js:761
|
||||||
msgid "Log Out"
|
msgid "Log Out"
|
||||||
msgstr "Logg ut"
|
msgstr "Logg ut"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:773
|
#: ../js/ui/userMenu.js:766
|
||||||
msgid "Lock"
|
msgid "Lock"
|
||||||
msgstr "Lås"
|
msgstr "Lås"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:788
|
#: ../js/ui/userMenu.js:781
|
||||||
msgid "Install Updates & Restart"
|
msgid "Install Updates & Restart"
|
||||||
msgstr "Installer oppdateringer og start på nytt"
|
msgstr "Installer oppdateringer og start på nytt"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:806
|
#: ../js/ui/userMenu.js:799
|
||||||
msgid "Your chat status will be set to busy"
|
msgid "Your chat status will be set to busy"
|
||||||
msgstr "Din pratestatus vil bli satt til opptatt"
|
msgstr "Din pratestatus vil bli satt til opptatt"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:807
|
#: ../js/ui/userMenu.js:800
|
||||||
msgid ""
|
msgid ""
|
||||||
"Notifications are now disabled, including chat messages. Your online status "
|
"Notifications are now disabled, including chat messages. Your online status "
|
||||||
"has been adjusted to let others know that you might not see their messages."
|
"has been adjusted to let others know that you might not see their messages."
|
||||||
@ -1709,15 +1644,15 @@ msgstr ""
|
|||||||
"tilkoblingsstatus er justert for å la andre vite at du kanskje ikke ser "
|
"tilkoblingsstatus er justert for å la andre vite at du kanskje ikke ser "
|
||||||
"deres meldinger."
|
"deres meldinger."
|
||||||
|
|
||||||
#: ../js/ui/viewSelector.js:87
|
#: ../js/ui/viewSelector.js:85
|
||||||
msgid "Windows"
|
msgid "Windows"
|
||||||
msgstr "Vinduer"
|
msgstr "Vinduer"
|
||||||
|
|
||||||
#: ../js/ui/viewSelector.js:91
|
#: ../js/ui/viewSelector.js:89
|
||||||
msgid "Applications"
|
msgid "Applications"
|
||||||
msgstr "Programmer"
|
msgstr "Programmer"
|
||||||
|
|
||||||
#: ../js/ui/viewSelector.js:95
|
#: ../js/ui/viewSelector.js:93
|
||||||
msgid "Search"
|
msgid "Search"
|
||||||
msgstr "Søk"
|
msgstr "Søk"
|
||||||
|
|
||||||
@ -1786,7 +1721,7 @@ msgstr "Bruk spesifikt modus, f.eks «gdm» for innloggingsskjerm"
|
|||||||
msgid "List possible modes"
|
msgid "List possible modes"
|
||||||
msgstr "Vis mulige modi"
|
msgstr "Vis mulige modi"
|
||||||
|
|
||||||
#: ../src/shell-app.c:622
|
#: ../src/shell-app.c:621
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Failed to launch '%s'"
|
msgid "Failed to launch '%s'"
|
||||||
msgstr "Klarte ikke å starte «%s»"
|
msgstr "Klarte ikke å starte «%s»"
|
||||||
|
262
po/ru.po
262
po/ru.po
@ -15,8 +15,8 @@ msgstr ""
|
|||||||
"Project-Id-Version: gnome-shell\n"
|
"Project-Id-Version: gnome-shell\n"
|
||||||
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-"
|
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-"
|
||||||
"shell&keywords=I18N+L10N&component=general\n"
|
"shell&keywords=I18N+L10N&component=general\n"
|
||||||
"POT-Creation-Date: 2012-10-31 16:48+0000\n"
|
"POT-Creation-Date: 2012-09-25 00:06+0000\n"
|
||||||
"PO-Revision-Date: 2012-11-04 20:48+0400\n"
|
"PO-Revision-Date: 2012-09-27 16:38+0400\n"
|
||||||
"Last-Translator: Yuri Myasoedov <omerta13@yandex.ru>\n"
|
"Last-Translator: Yuri Myasoedov <omerta13@yandex.ru>\n"
|
||||||
"Language-Team: русский <gnome-cyr@gnome.org>\n"
|
"Language-Team: русский <gnome-cyr@gnome.org>\n"
|
||||||
"Language: ru\n"
|
"Language: ru\n"
|
||||||
@ -141,63 +141,51 @@ msgstr ""
|
|||||||
"Данное значение берётся из перечисления GsmPresenceStatus."
|
"Данное значение берётся из перечисления GsmPresenceStatus."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:13
|
||||||
msgid "Always show the 'Log out' menuitem in the user menu."
|
|
||||||
msgstr "Всегда показывать в меню пункт «Завершить сеанс»."
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
|
||||||
msgid ""
|
|
||||||
"This key overrides the automatic hiding of the 'Log out' menuitem in single-"
|
|
||||||
"user, single-session situations."
|
|
||||||
msgstr ""
|
|
||||||
"Этот ключ переопределяет автоматическое скрытие пункта «Завершить сеанс» при "
|
|
||||||
"использовании одиночного сеанса."
|
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
|
||||||
msgid "Show the week date in the calendar"
|
msgid "Show the week date in the calendar"
|
||||||
msgstr "Показывать в часах дату недели"
|
msgstr "Показывать в часах дату недели"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:14
|
||||||
msgid "If true, display the ISO week date in the calendar."
|
msgid "If true, display the ISO week date in the calendar."
|
||||||
msgstr "Если установлено, календарь будет показывать неделю в формате ISO."
|
msgstr "Если установлено, календарь будет показывать неделю в формате ISO."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:15
|
||||||
msgid "Keybinding to open the application menu"
|
msgid "Keybinding to open the application menu"
|
||||||
msgstr "Комбинация клавиш для открытия меню приложения"
|
msgstr "Комбинация клавиш для открытия меню приложения"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:16
|
||||||
msgid "Keybinding to open the application menu."
|
msgid "Keybinding to open the application menu."
|
||||||
msgstr "Комбинация клавиш для открытия меню приложения."
|
msgstr "Комбинация клавиш для открытия меню приложения."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:17
|
||||||
msgid "Keybinding to toggle the visibility of the message tray"
|
msgid "Keybinding to toggle the visibility of the message tray"
|
||||||
msgstr "Комбинация клавиш для переключения видимости панели сообщений"
|
msgstr "Комбинация клавиш для переключения видимости панели сообщений"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:18
|
||||||
msgid "Keybinding to toggle the visibility of the message tray."
|
msgid "Keybinding to toggle the visibility of the message tray."
|
||||||
msgstr "Комбинация клавиш для переключения видимости панели сообщений."
|
msgstr "Комбинация клавиш для переключения видимости панели сообщений."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:19
|
||||||
msgid "Keybinding to toggle the screen recorder"
|
msgid "Keybinding to toggle the screen recorder"
|
||||||
msgstr "Комбинация клавиш для переключения записи экрана"
|
msgstr "Комбинация клавиш для переключения записи экрана"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:20
|
||||||
msgid "Keybinding to start/stop the builtin screen recorder."
|
msgid "Keybinding to start/stop the builtin screen recorder."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Комбинация клавиш для запуска/остановки встроенного средства записи экрана."
|
"Комбинация клавиш для запуска/остановки встроенного средства записи экрана."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:21
|
||||||
msgid "Which keyboard to use"
|
msgid "Which keyboard to use"
|
||||||
msgstr "Какую клавиатуру использовать"
|
msgstr "Какую клавиатуру использовать"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:22
|
||||||
msgid "The type of keyboard to use."
|
msgid "The type of keyboard to use."
|
||||||
msgstr "Тип используемой клавиатуры."
|
msgstr "Тип используемой клавиатуры."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:23
|
||||||
msgid "Framerate used for recording screencasts."
|
msgid "Framerate used for recording screencasts."
|
||||||
msgstr "Частота смены кадров для записи скринкастов."
|
msgstr "Частота смены кадров для записи скринкастов."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:26
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:24
|
||||||
msgid ""
|
msgid ""
|
||||||
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
"The framerate of the resulting screencast recordered by GNOME Shell's "
|
||||||
"screencast recorder in frames-per-second."
|
"screencast recorder in frames-per-second."
|
||||||
@ -205,11 +193,11 @@ msgstr ""
|
|||||||
"Частота смены кадров в скринкасте, записанном с помощью GNOME Shell (кадров/"
|
"Частота смены кадров в скринкасте, записанном с помощью GNOME Shell (кадров/"
|
||||||
"сек)."
|
"сек)."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:25
|
||||||
msgid "The gstreamer pipeline used to encode the screencast"
|
msgid "The gstreamer pipeline used to encode the screencast"
|
||||||
msgstr "Конвейер gstreamer, используемый для кодирования скринкастов"
|
msgstr "Конвейер gstreamer, используемый для кодирования скринкастов"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:27
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid ""
|
msgid ""
|
||||||
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
"Sets the GStreamer pipeline used to encode recordings. It follows the syntax "
|
||||||
@ -236,11 +224,11 @@ msgstr ""
|
|||||||
"используется как заполнитель для определения оптимального количества потоков "
|
"используется как заполнитель для определения оптимального количества потоков "
|
||||||
"в системе."
|
"в системе."
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:30
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:28
|
||||||
msgid "File extension used for storing the screencast"
|
msgid "File extension used for storing the screencast"
|
||||||
msgstr "Расширение файла, использующееся для хранения скринкастов"
|
msgstr "Расширение файла, использующееся для хранения скринкастов"
|
||||||
|
|
||||||
#: ../data/org.gnome.shell.gschema.xml.in.in.h:31
|
#: ../data/org.gnome.shell.gschema.xml.in.in.h:29
|
||||||
msgid ""
|
msgid ""
|
||||||
"The filename for recorded screencasts will be a unique filename based on the "
|
"The filename for recorded screencasts will be a unique filename based on the "
|
||||||
"current date, and use this extension. It should be changed when recording to "
|
"current date, and use this extension. It should be changed when recording to "
|
||||||
@ -263,11 +251,11 @@ msgstr "Расширение"
|
|||||||
msgid "Select an extension to configure using the combobox above."
|
msgid "Select an extension to configure using the combobox above."
|
||||||
msgstr "Выберите расширение из выпадающего списка."
|
msgstr "Выберите расширение из выпадающего списка."
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:529
|
#: ../js/gdm/loginDialog.js:527
|
||||||
msgid "Session..."
|
msgid "Session..."
|
||||||
msgstr "Сеанс…"
|
msgstr "Сеанс…"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:677
|
#: ../js/gdm/loginDialog.js:675
|
||||||
msgctxt "title"
|
msgctxt "title"
|
||||||
msgid "Sign In"
|
msgid "Sign In"
|
||||||
msgstr "Вход в систему"
|
msgstr "Вход в систему"
|
||||||
@ -275,33 +263,34 @@ msgstr "Вход в систему"
|
|||||||
#. translators: this message is shown below the user list on the
|
#. translators: this message is shown below the user list on the
|
||||||
#. login screen. It can be activated to reveal an entry for
|
#. login screen. It can be activated to reveal an entry for
|
||||||
#. manually entering the username.
|
#. manually entering the username.
|
||||||
#: ../js/gdm/loginDialog.js:736
|
#: ../js/gdm/loginDialog.js:742
|
||||||
msgid "Not listed?"
|
msgid "Not listed?"
|
||||||
msgstr "Нет в списке?"
|
msgstr "Нет в списке?"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:889 ../js/ui/components/networkAgent.js:137
|
#: ../js/gdm/loginDialog.js:895 ../js/ui/components/networkAgent.js:137
|
||||||
#: ../js/ui/components/polkitAgent.js:162 ../js/ui/endSessionDialog.js:373
|
#: ../js/ui/components/polkitAgent.js:162 ../js/ui/endSessionDialog.js:373
|
||||||
#: ../js/ui/extensionDownloader.js:195 ../js/ui/shellMountOperation.js:396
|
#: ../js/ui/extensionDownloader.js:195 ../js/ui/shellMountOperation.js:396
|
||||||
#: ../js/ui/status/bluetooth.js:427 ../js/ui/unlockDialog.js:167
|
#: ../js/ui/status/bluetooth.js:427 ../js/ui/unlockDialog.js:166
|
||||||
msgid "Cancel"
|
msgid "Cancel"
|
||||||
msgstr "Отмена"
|
msgstr "Отмена"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:894
|
#: ../js/gdm/loginDialog.js:900
|
||||||
msgctxt "button"
|
msgctxt "button"
|
||||||
msgid "Sign In"
|
msgid "Sign In"
|
||||||
msgstr "Войти"
|
msgstr "Войти"
|
||||||
|
|
||||||
#: ../js/gdm/loginDialog.js:1215
|
#: ../js/gdm/loginDialog.js:1239
|
||||||
msgid "Login Window"
|
msgid "Login Window"
|
||||||
msgstr "Окно входа в систему"
|
msgstr "Окно входа в систему"
|
||||||
|
|
||||||
#. Translators: accessible name of the power menu in the login screen
|
#. Translators: accessible name of the power menu in the login screen
|
||||||
#: ../js/gdm/powerMenu.js:35
|
#: ../js/gdm/powerMenu.js:35
|
||||||
|
#| msgid "Power Off"
|
||||||
msgid "Power"
|
msgid "Power"
|
||||||
msgstr "Питание"
|
msgstr "Питание"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:89 ../js/ui/userMenu.js:664 ../js/ui/userMenu.js:668
|
#: ../js/gdm/powerMenu.js:89 ../js/ui/userMenu.js:663 ../js/ui/userMenu.js:667
|
||||||
#: ../js/ui/userMenu.js:779
|
#: ../js/ui/userMenu.js:778
|
||||||
msgid "Suspend"
|
msgid "Suspend"
|
||||||
msgstr "Ждущий режим"
|
msgstr "Ждущий режим"
|
||||||
|
|
||||||
@ -309,8 +298,8 @@ msgstr "Ждущий режим"
|
|||||||
msgid "Restart"
|
msgid "Restart"
|
||||||
msgstr "Перезапустить"
|
msgstr "Перезапустить"
|
||||||
|
|
||||||
#: ../js/gdm/powerMenu.js:99 ../js/ui/userMenu.js:666 ../js/ui/userMenu.js:668
|
#: ../js/gdm/powerMenu.js:99 ../js/ui/userMenu.js:665 ../js/ui/userMenu.js:667
|
||||||
#: ../js/ui/userMenu.js:778
|
#: ../js/ui/userMenu.js:777
|
||||||
msgid "Power Off"
|
msgid "Power Off"
|
||||||
msgstr "Выключить"
|
msgstr "Выключить"
|
||||||
|
|
||||||
@ -361,7 +350,7 @@ msgstr "НАСТРОЙКИ"
|
|||||||
msgid "New Window"
|
msgid "New Window"
|
||||||
msgstr "Новое окно"
|
msgstr "Новое окно"
|
||||||
|
|
||||||
#: ../js/ui/appDisplay.js:678 ../js/ui/dash.js:290
|
#: ../js/ui/appDisplay.js:678 ../js/ui/dash.js:271
|
||||||
msgid "Remove from Favorites"
|
msgid "Remove from Favorites"
|
||||||
msgstr "Удалить из избранного"
|
msgstr "Удалить из избранного"
|
||||||
|
|
||||||
@ -525,16 +514,16 @@ msgstr "Эта неделя"
|
|||||||
msgid "Next week"
|
msgid "Next week"
|
||||||
msgstr "Следующая неделя"
|
msgstr "Следующая неделя"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:297
|
#: ../js/ui/components/autorunManager.js:278
|
||||||
msgid "Removable Devices"
|
msgid "Removable Devices"
|
||||||
msgstr "Cъёмные устройства"
|
msgstr "Cъёмные устройства"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:594
|
#: ../js/ui/components/autorunManager.js:575
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Open with %s"
|
msgid "Open with %s"
|
||||||
msgstr "Открыть с помощью %s"
|
msgstr "Открыть с помощью %s"
|
||||||
|
|
||||||
#: ../js/ui/components/autorunManager.js:620
|
#: ../js/ui/components/autorunManager.js:601
|
||||||
msgid "Eject"
|
msgid "Eject"
|
||||||
msgstr "Извлечь"
|
msgstr "Извлечь"
|
||||||
|
|
||||||
@ -690,35 +679,35 @@ msgstr "Приглушить звук"
|
|||||||
#. Translators: this is a time format string followed by a date.
|
#. Translators: this is a time format string followed by a date.
|
||||||
#. If applicable, replace %X with a strftime format valid for your
|
#. If applicable, replace %X with a strftime format valid for your
|
||||||
#. locale, without seconds.
|
#. locale, without seconds.
|
||||||
#: ../js/ui/components/telepathyClient.js:950
|
#: ../js/ui/components/telepathyClient.js:948
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent at <b>%X</b> on <b>%A</b>"
|
msgid "Sent at <b>%X</b> on <b>%A</b>"
|
||||||
msgstr "Отправлено в <b>%X</b> в <b>%A</b>"
|
msgstr "Отправлено в <b>%X</b> в <b>%A</b>"
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "Wednesday, May 25",
|
#. Translators: this is a time format in the style of "Wednesday, May 25",
|
||||||
#. shown when you get a chat message in the same year.
|
#. shown when you get a chat message in the same year.
|
||||||
#: ../js/ui/components/telepathyClient.js:956
|
#: ../js/ui/components/telepathyClient.js:954
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent on <b>%A</b>, <b>%B %d</b>"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>"
|
||||||
msgstr "Отправлено в <b>%A</b>, <b>%B %d</b>"
|
msgstr "Отправлено в <b>%A</b>, <b>%B %d</b>"
|
||||||
|
|
||||||
#. Translators: this is a time format in the style of "Wednesday, May 25, 2012",
|
#. Translators: this is a time format in the style of "Wednesday, May 25, 2012",
|
||||||
#. shown when you get a chat message in a different year.
|
#. shown when you get a chat message in a different year.
|
||||||
#: ../js/ui/components/telepathyClient.js:961
|
#: ../js/ui/components/telepathyClient.js:959
|
||||||
#, no-c-format
|
#, no-c-format
|
||||||
msgid "Sent on <b>%A</b>, <b>%B %d</b>, %Y"
|
msgid "Sent on <b>%A</b>, <b>%B %d</b>, %Y"
|
||||||
msgstr "Отправлено в <b>%A</b>, <b>%B %d</b>, %Y"
|
msgstr "Отправлено в <b>%A</b>, <b>%B %d</b>, %Y"
|
||||||
|
|
||||||
#. Translators: this is the other person changing their old IM name to their new
|
#. Translators: this is the other person changing their old IM name to their new
|
||||||
#. IM name.
|
#. IM name.
|
||||||
#: ../js/ui/components/telepathyClient.js:990
|
#: ../js/ui/components/telepathyClient.js:988
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is now known as %s"
|
msgid "%s is now known as %s"
|
||||||
msgstr "%s теперь известен как %s"
|
msgstr "%s теперь известен как %s"
|
||||||
|
|
||||||
#. translators: argument is a room name like
|
#. translators: argument is a room name like
|
||||||
#. * room@jabber.org for example.
|
#. * room@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1090
|
#: ../js/ui/components/telepathyClient.js:1088
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Invitation to %s"
|
msgid "Invitation to %s"
|
||||||
msgstr "Приглашение в %s"
|
msgstr "Приглашение в %s"
|
||||||
@ -726,42 +715,42 @@ msgstr "Приглашение в %s"
|
|||||||
#. translators: first argument is the name of a contact and the second
|
#. translators: first argument is the name of a contact and the second
|
||||||
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
#. * one the name of a room. "Alice is inviting you to join room@jabber.org
|
||||||
#. * for example.
|
#. * for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1098
|
#: ../js/ui/components/telepathyClient.js:1096
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is inviting you to join %s"
|
msgid "%s is inviting you to join %s"
|
||||||
msgstr "%s приглашает вас присоединиться к %s"
|
msgstr "%s приглашает вас присоединиться к %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1100
|
#: ../js/ui/components/telepathyClient.js:1098
|
||||||
#: ../js/ui/components/telepathyClient.js:1179
|
#: ../js/ui/components/telepathyClient.js:1177
|
||||||
#: ../js/ui/components/telepathyClient.js:1242
|
#: ../js/ui/components/telepathyClient.js:1240
|
||||||
msgid "Decline"
|
msgid "Decline"
|
||||||
msgstr "Отказаться"
|
msgstr "Отказаться"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1101
|
#: ../js/ui/components/telepathyClient.js:1099
|
||||||
#: ../js/ui/components/telepathyClient.js:1180
|
#: ../js/ui/components/telepathyClient.js:1178
|
||||||
#: ../js/ui/components/telepathyClient.js:1243
|
#: ../js/ui/components/telepathyClient.js:1241
|
||||||
msgid "Accept"
|
msgid "Accept"
|
||||||
msgstr "Принять"
|
msgstr "Принять"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1131
|
#: ../js/ui/components/telepathyClient.js:1129
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Video call from %s"
|
msgid "Video call from %s"
|
||||||
msgstr "Вас вызывает %s по видео"
|
msgstr "Вас вызывает %s по видео"
|
||||||
|
|
||||||
#. translators: argument is a contact name like Alice for example.
|
#. translators: argument is a contact name like Alice for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1134
|
#: ../js/ui/components/telepathyClient.js:1132
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Call from %s"
|
msgid "Call from %s"
|
||||||
msgstr "Вас вызывает %s"
|
msgstr "Вас вызывает %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1139
|
#: ../js/ui/components/telepathyClient.js:1137
|
||||||
#: ../js/ui/status/bluetooth.js:346
|
#: ../js/ui/status/bluetooth.js:346
|
||||||
msgid "Reject"
|
msgid "Reject"
|
||||||
msgstr "Отклонить"
|
msgstr "Отклонить"
|
||||||
|
|
||||||
#. translators: this is a button label (verb), not a noun
|
#. translators: this is a button label (verb), not a noun
|
||||||
#: ../js/ui/components/telepathyClient.js:1141
|
#: ../js/ui/components/telepathyClient.js:1139
|
||||||
msgid "Answer"
|
msgid "Answer"
|
||||||
msgstr "Ответить"
|
msgstr "Ответить"
|
||||||
|
|
||||||
@ -770,111 +759,111 @@ msgstr "Ответить"
|
|||||||
#. * file name. The string will be something
|
#. * file name. The string will be something
|
||||||
#. * like: "Alice is sending you test.ogg"
|
#. * like: "Alice is sending you test.ogg"
|
||||||
#.
|
#.
|
||||||
#: ../js/ui/components/telepathyClient.js:1173
|
#: ../js/ui/components/telepathyClient.js:1171
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is sending you %s"
|
msgid "%s is sending you %s"
|
||||||
msgstr "%s отправляет вам %s"
|
msgstr "%s отправляет вам %s"
|
||||||
|
|
||||||
#. To translators: The parameter is the contact's alias
|
#. To translators: The parameter is the contact's alias
|
||||||
#: ../js/ui/components/telepathyClient.js:1208
|
#: ../js/ui/components/telepathyClient.js:1206
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s would like permission to see when you are online"
|
msgid "%s would like permission to see when you are online"
|
||||||
msgstr "%s хотел бы получить разрешение видеть, когда вы в сети"
|
msgstr "%s хотел бы получить разрешение видеть, когда вы в сети"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1300
|
#: ../js/ui/components/telepathyClient.js:1298
|
||||||
msgid "Network error"
|
msgid "Network error"
|
||||||
msgstr "Ошибка сети"
|
msgstr "Ошибка сети"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1302
|
#: ../js/ui/components/telepathyClient.js:1300
|
||||||
msgid "Authentication failed"
|
msgid "Authentication failed"
|
||||||
msgstr "Ошибка аутентификации"
|
msgstr "Ошибка аутентификации"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1304
|
#: ../js/ui/components/telepathyClient.js:1302
|
||||||
msgid "Encryption error"
|
msgid "Encryption error"
|
||||||
msgstr "Ошибка шифрования"
|
msgstr "Ошибка шифрования"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1306
|
#: ../js/ui/components/telepathyClient.js:1304
|
||||||
msgid "Certificate not provided"
|
msgid "Certificate not provided"
|
||||||
msgstr "Сертификат не предоставляется"
|
msgstr "Сертификат не предоставляется"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1308
|
#: ../js/ui/components/telepathyClient.js:1306
|
||||||
msgid "Certificate untrusted"
|
msgid "Certificate untrusted"
|
||||||
msgstr "Недоверенный сертификат"
|
msgstr "Недоверенный сертификат"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1310
|
#: ../js/ui/components/telepathyClient.js:1308
|
||||||
msgid "Certificate expired"
|
msgid "Certificate expired"
|
||||||
msgstr "Срок действия сертификата истёк"
|
msgstr "Срок действия сертификата истёк"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1312
|
#: ../js/ui/components/telepathyClient.js:1310
|
||||||
msgid "Certificate not activated"
|
msgid "Certificate not activated"
|
||||||
msgstr "Сертификат не активирован"
|
msgstr "Сертификат не активирован"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1314
|
#: ../js/ui/components/telepathyClient.js:1312
|
||||||
msgid "Certificate hostname mismatch"
|
msgid "Certificate hostname mismatch"
|
||||||
msgstr "Имя узла сертификата не совпадает"
|
msgstr "Имя узла сертификата не совпадает"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1316
|
#: ../js/ui/components/telepathyClient.js:1314
|
||||||
msgid "Certificate fingerprint mismatch"
|
msgid "Certificate fingerprint mismatch"
|
||||||
msgstr "Отпечаток сертификата не совпадает"
|
msgstr "Отпечаток сертификата не совпадает"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1318
|
#: ../js/ui/components/telepathyClient.js:1316
|
||||||
msgid "Certificate self-signed"
|
msgid "Certificate self-signed"
|
||||||
msgstr "Самоподписанный сертификат"
|
msgstr "Самоподписанный сертификат"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1320
|
#: ../js/ui/components/telepathyClient.js:1318
|
||||||
msgid "Status is set to offline"
|
msgid "Status is set to offline"
|
||||||
msgstr "Установлен статус «не в сети»"
|
msgstr "Установлен статус «не в сети»"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1322
|
#: ../js/ui/components/telepathyClient.js:1320
|
||||||
msgid "Encryption is not available"
|
msgid "Encryption is not available"
|
||||||
msgstr "Шифрование недоступно"
|
msgstr "Шифрование недоступно"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1324
|
#: ../js/ui/components/telepathyClient.js:1322
|
||||||
msgid "Certificate is invalid"
|
msgid "Certificate is invalid"
|
||||||
msgstr "Недействительный сертификат"
|
msgstr "Недействительный сертификат"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1326
|
#: ../js/ui/components/telepathyClient.js:1324
|
||||||
msgid "Connection has been refused"
|
msgid "Connection has been refused"
|
||||||
msgstr "В соединении отказано"
|
msgstr "В соединении отказано"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1328
|
#: ../js/ui/components/telepathyClient.js:1326
|
||||||
msgid "Connection can't be established"
|
msgid "Connection can't be established"
|
||||||
msgstr "Соединение не может быть установлено"
|
msgstr "Соединение не может быть установлено"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1330
|
#: ../js/ui/components/telepathyClient.js:1328
|
||||||
msgid "Connection has been lost"
|
msgid "Connection has been lost"
|
||||||
msgstr "Соединение потеряно"
|
msgstr "Соединение потеряно"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1332
|
#: ../js/ui/components/telepathyClient.js:1330
|
||||||
msgid "This account is already connected to the server"
|
msgid "This account is already connected to the server"
|
||||||
msgstr "Эта учётная запись уже подключена к серверу"
|
msgstr "Эта учётная запись уже подключена к серверу"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1334
|
#: ../js/ui/components/telepathyClient.js:1332
|
||||||
msgid ""
|
msgid ""
|
||||||
"Connection has been replaced by a new connection using the same resource"
|
"Connection has been replaced by a new connection using the same resource"
|
||||||
msgstr "Соединение было заменено новым, используя тот же источник"
|
msgstr "Соединение было заменено новым, используя тот же источник"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1336
|
#: ../js/ui/components/telepathyClient.js:1334
|
||||||
msgid "The account already exists on the server"
|
msgid "The account already exists on the server"
|
||||||
msgstr "Учётная запись уже существует на сервере"
|
msgstr "Учётная запись уже существует на сервере"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1338
|
#: ../js/ui/components/telepathyClient.js:1336
|
||||||
msgid "Server is currently too busy to handle the connection"
|
msgid "Server is currently too busy to handle the connection"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Сервер в настоящее время сильно перегружен, чтобы обработать соединение"
|
"Сервер в настоящее время сильно перегружен, чтобы обработать соединение"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1340
|
#: ../js/ui/components/telepathyClient.js:1338
|
||||||
msgid "Certificate has been revoked"
|
msgid "Certificate has been revoked"
|
||||||
msgstr "Сертификат аннулирован"
|
msgstr "Сертификат аннулирован"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1342
|
#: ../js/ui/components/telepathyClient.js:1340
|
||||||
msgid ""
|
msgid ""
|
||||||
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
"Certificate uses an insecure cipher algorithm or is cryptographically weak"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Сертификат использует небезопасный алгоритм шифрования или он "
|
"Сертификат использует небезопасный алгоритм шифрования или он "
|
||||||
"криптографически нестоек"
|
"криптографически нестоек"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1344
|
#: ../js/ui/components/telepathyClient.js:1342
|
||||||
msgid ""
|
msgid ""
|
||||||
"The length of the server certificate, or the depth of the server certificate "
|
"The length of the server certificate, or the depth of the server certificate "
|
||||||
"chain, exceed the limits imposed by the cryptography library"
|
"chain, exceed the limits imposed by the cryptography library"
|
||||||
@ -882,30 +871,30 @@ msgstr ""
|
|||||||
"Длина сертификата сервера, или глубина цепочки сертификатов сервера, "
|
"Длина сертификата сервера, или глубина цепочки сертификатов сервера, "
|
||||||
"превышает пределы, установленные библиотекой криптографии"
|
"превышает пределы, установленные библиотекой криптографии"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1346
|
#: ../js/ui/components/telepathyClient.js:1344
|
||||||
msgid "Internal error"
|
msgid "Internal error"
|
||||||
msgstr "Внутренняя ошибка"
|
msgstr "Внутренняя ошибка"
|
||||||
|
|
||||||
#. translators: argument is the account name, like
|
#. translators: argument is the account name, like
|
||||||
#. * name@jabber.org for example.
|
#. * name@jabber.org for example.
|
||||||
#: ../js/ui/components/telepathyClient.js:1356
|
#: ../js/ui/components/telepathyClient.js:1354
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Connection to %s failed"
|
msgid "Connection to %s failed"
|
||||||
msgstr "Сбой подключения к %s"
|
msgstr "Сбой подключения к %s"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1365
|
#: ../js/ui/components/telepathyClient.js:1363
|
||||||
msgid "Reconnect"
|
msgid "Reconnect"
|
||||||
msgstr "Переподключиться"
|
msgstr "Переподключиться"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1366
|
#: ../js/ui/components/telepathyClient.js:1364
|
||||||
msgid "Edit account"
|
msgid "Edit account"
|
||||||
msgstr "Изменить учётную запись"
|
msgstr "Изменить учётную запись"
|
||||||
|
|
||||||
#: ../js/ui/components/telepathyClient.js:1411
|
#: ../js/ui/components/telepathyClient.js:1409
|
||||||
msgid "Unknown reason"
|
msgid "Unknown reason"
|
||||||
msgstr "Неизвестная причина"
|
msgstr "Неизвестная причина"
|
||||||
|
|
||||||
#: ../js/ui/dash.js:253 ../js/ui/dash.js:292
|
#: ../js/ui/dash.js:245 ../js/ui/dash.js:273
|
||||||
msgid "Show Applications"
|
msgid "Show Applications"
|
||||||
msgstr "Показать приложения"
|
msgstr "Показать приложения"
|
||||||
|
|
||||||
@ -913,14 +902,14 @@ msgstr "Показать приложения"
|
|||||||
msgid "Date and Time Settings"
|
msgid "Date and Time Settings"
|
||||||
msgstr "Настроить дату и время"
|
msgstr "Настроить дату и время"
|
||||||
|
|
||||||
#: ../js/ui/dateMenu.js:111
|
#: ../js/ui/dateMenu.js:109
|
||||||
msgid "Open Calendar"
|
msgid "Open Calendar"
|
||||||
msgstr "Открыть календарь"
|
msgstr "Открыть календарь"
|
||||||
|
|
||||||
#. Translators: This is the date format to use when the calendar popup is
|
#. Translators: This is the date format to use when the calendar popup is
|
||||||
#. * shown - it is shown just below the time in the shell (e.g. "Tue 9:29 AM").
|
#. * shown - it is shown just below the time in the shell (e.g. "Tue 9:29 AM").
|
||||||
#.
|
#.
|
||||||
#: ../js/ui/dateMenu.js:201
|
#: ../js/ui/dateMenu.js:175
|
||||||
msgid "%A %B %e, %Y"
|
msgid "%A %B %e, %Y"
|
||||||
msgstr "%A, %e %B, %Y"
|
msgstr "%A, %e %B, %Y"
|
||||||
|
|
||||||
@ -1030,11 +1019,11 @@ msgstr "Установить"
|
|||||||
msgid "Download and install '%s' from extensions.gnome.org?"
|
msgid "Download and install '%s' from extensions.gnome.org?"
|
||||||
msgstr "Загрузить и установить расширение «%s» с extensions.gnome.org?"
|
msgstr "Загрузить и установить расширение «%s» с extensions.gnome.org?"
|
||||||
|
|
||||||
#: ../js/ui/keyboard.js:337
|
#: ../js/ui/keyboard.js:327
|
||||||
msgid "tray"
|
msgid "tray"
|
||||||
msgstr "лоток"
|
msgstr "лоток"
|
||||||
|
|
||||||
#: ../js/ui/keyboard.js:584 ../js/ui/status/keyboard.js:195
|
#: ../js/ui/keyboard.js:561 ../js/ui/status/keyboard.js:195
|
||||||
#: ../js/ui/status/power.js:205
|
#: ../js/ui/status/power.js:205
|
||||||
msgid "Keyboard"
|
msgid "Keyboard"
|
||||||
msgstr "Клавиатура"
|
msgstr "Клавиатура"
|
||||||
@ -1087,23 +1076,23 @@ msgstr "Показать код"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Веб-страница"
|
msgstr "Веб-страница"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1084
|
#: ../js/ui/messageTray.js:1080
|
||||||
msgid "Open"
|
msgid "Open"
|
||||||
msgstr "Открыть"
|
msgstr "Открыть"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1091
|
#: ../js/ui/messageTray.js:1087
|
||||||
msgid "Remove"
|
msgid "Remove"
|
||||||
msgstr "Удалить"
|
msgstr "Удалить"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:1543
|
#: ../js/ui/messageTray.js:2055
|
||||||
msgid "Message Tray"
|
msgid "Message Tray"
|
||||||
msgstr "Панель сообщений"
|
msgstr "Панель сообщений"
|
||||||
|
|
||||||
#: ../js/ui/messageTray.js:2549
|
#: ../js/ui/messageTray.js:2511
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Системная информация"
|
msgstr "Системная информация"
|
||||||
|
|
||||||
#: ../js/ui/notificationDaemon.js:506 ../src/shell-app.c:374
|
#: ../js/ui/notificationDaemon.js:506 ../src/shell-app.c:373
|
||||||
msgctxt "program"
|
msgctxt "program"
|
||||||
msgid "Unknown"
|
msgid "Unknown"
|
||||||
msgstr "Неизвестно"
|
msgstr "Неизвестно"
|
||||||
@ -1159,7 +1148,7 @@ msgstr "Введите команду:"
|
|||||||
|
|
||||||
#. Translators: This is a time format for a date in
|
#. Translators: This is a time format for a date in
|
||||||
#. long format
|
#. long format
|
||||||
#: ../js/ui/screenShield.js:80
|
#: ../js/ui/screenShield.js:79
|
||||||
msgid "%A, %B %d"
|
msgid "%A, %B %d"
|
||||||
msgstr "%d %B, %A"
|
msgstr "%d %B, %A"
|
||||||
|
|
||||||
@ -1211,7 +1200,7 @@ msgstr "Пароль"
|
|||||||
msgid "Remember Password"
|
msgid "Remember Password"
|
||||||
msgstr "Запомнить пароль"
|
msgstr "Запомнить пароль"
|
||||||
|
|
||||||
#: ../js/ui/shellMountOperation.js:400 ../js/ui/unlockDialog.js:170
|
#: ../js/ui/shellMountOperation.js:400 ../js/ui/unlockDialog.js:169
|
||||||
msgid "Unlock"
|
msgid "Unlock"
|
||||||
msgstr "Разблокировать"
|
msgstr "Разблокировать"
|
||||||
|
|
||||||
@ -1329,7 +1318,7 @@ msgstr "Настроить клавиатуру"
|
|||||||
msgid "Mouse Settings"
|
msgid "Mouse Settings"
|
||||||
msgstr "Настроить мышь"
|
msgstr "Настроить мышь"
|
||||||
|
|
||||||
#: ../js/ui/status/bluetooth.js:269 ../js/ui/status/volume.js:234
|
#: ../js/ui/status/bluetooth.js:269 ../js/ui/status/volume.js:236
|
||||||
msgid "Sound Settings"
|
msgid "Sound Settings"
|
||||||
msgstr "Настроить звук"
|
msgstr "Настроить звук"
|
||||||
|
|
||||||
@ -1618,7 +1607,7 @@ msgid "Unknown"
|
|||||||
msgstr "Неизвестно"
|
msgstr "Неизвестно"
|
||||||
|
|
||||||
#. Translators: This is the label for audio volume
|
#. Translators: This is the label for audio volume
|
||||||
#: ../js/ui/status/volume.js:47 ../js/ui/status/volume.js:221
|
#: ../js/ui/status/volume.js:47 ../js/ui/status/volume.js:223
|
||||||
msgid "Volume"
|
msgid "Volume"
|
||||||
msgstr "Громкость"
|
msgstr "Громкость"
|
||||||
|
|
||||||
@ -1626,63 +1615,67 @@ msgstr "Громкость"
|
|||||||
msgid "Microphone"
|
msgid "Microphone"
|
||||||
msgstr "Микрофон"
|
msgstr "Микрофон"
|
||||||
|
|
||||||
#: ../js/ui/unlockDialog.js:177
|
#: ../js/ui/unlockDialog.js:176
|
||||||
msgid "Log in as another user"
|
msgid "Log in as another user"
|
||||||
msgstr "Войти от имени другого пользователя"
|
msgstr "Войти от имени другого пользователя"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:181
|
#: ../js/ui/userMenu.js:180
|
||||||
msgid "Available"
|
msgid "Available"
|
||||||
msgstr "Доступен"
|
msgstr "Доступен"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:184
|
#: ../js/ui/userMenu.js:183
|
||||||
msgid "Busy"
|
msgid "Busy"
|
||||||
msgstr "Занят"
|
msgstr "Занят"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:187
|
#: ../js/ui/userMenu.js:186
|
||||||
msgid "Invisible"
|
msgid "Invisible"
|
||||||
msgstr "Невидим"
|
msgstr "Невидим"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:190
|
#: ../js/ui/userMenu.js:189
|
||||||
msgid "Away"
|
msgid "Away"
|
||||||
msgstr "Отошёл"
|
msgstr "Отошёл"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:193
|
#: ../js/ui/userMenu.js:192
|
||||||
msgid "Idle"
|
msgid "Idle"
|
||||||
msgstr "Бездействует"
|
msgstr "Бездействует"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:196
|
#: ../js/ui/userMenu.js:195
|
||||||
msgid "Unavailable"
|
msgid "Unavailable"
|
||||||
msgstr "Недоступен"
|
msgstr "Недоступен"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:744
|
#: ../js/ui/userMenu.js:618 ../js/ui/userMenu.js:759
|
||||||
msgid "Notifications"
|
|
||||||
msgstr "Уведомления"
|
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:752
|
|
||||||
msgid "System Settings"
|
|
||||||
msgstr "Системные параметры"
|
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:760
|
|
||||||
msgid "Switch User"
|
msgid "Switch User"
|
||||||
msgstr "Сменить пользователя"
|
msgstr "Сменить пользователя"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:765
|
#: ../js/ui/userMenu.js:619
|
||||||
|
msgid "Switch Session"
|
||||||
|
msgstr "Переключить сеанс"
|
||||||
|
|
||||||
|
#: ../js/ui/userMenu.js:743
|
||||||
|
msgid "Notifications"
|
||||||
|
msgstr "Уведомления"
|
||||||
|
|
||||||
|
#: ../js/ui/userMenu.js:751
|
||||||
|
msgid "System Settings"
|
||||||
|
msgstr "Системные параметры"
|
||||||
|
|
||||||
|
#: ../js/ui/userMenu.js:764
|
||||||
msgid "Log Out"
|
msgid "Log Out"
|
||||||
msgstr "Выйти из системы"
|
msgstr "Выйти из системы"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:770
|
#: ../js/ui/userMenu.js:769
|
||||||
msgid "Lock"
|
msgid "Lock"
|
||||||
msgstr "Заблокировать"
|
msgstr "Заблокировать"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:785
|
#: ../js/ui/userMenu.js:784
|
||||||
msgid "Install Updates & Restart"
|
msgid "Install Updates & Restart"
|
||||||
msgstr "Установить обновления и выполнить перезагрузку"
|
msgstr "Установить обновления и выполнить перезагрузку"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:803
|
#: ../js/ui/userMenu.js:802
|
||||||
msgid "Your chat status will be set to busy"
|
msgid "Your chat status will be set to busy"
|
||||||
msgstr "Будет установлен статус «не беспокоить»"
|
msgstr "Будет установлен статус «не беспокоить»"
|
||||||
|
|
||||||
#: ../js/ui/userMenu.js:804
|
#: ../js/ui/userMenu.js:803
|
||||||
msgid ""
|
msgid ""
|
||||||
"Notifications are now disabled, including chat messages. Your online status "
|
"Notifications are now disabled, including chat messages. Your online status "
|
||||||
"has been adjusted to let others know that you might not see their messages."
|
"has been adjusted to let others know that you might not see their messages."
|
||||||
@ -1702,7 +1695,7 @@ msgstr "Приложения"
|
|||||||
msgid "Search"
|
msgid "Search"
|
||||||
msgstr "Поиск"
|
msgstr "Поиск"
|
||||||
|
|
||||||
#: ../js/ui/wanda.js:117
|
#: ../js/ui/wanda.js:119
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid ""
|
msgid ""
|
||||||
"Sorry, no wisdom for you today:\n"
|
"Sorry, no wisdom for you today:\n"
|
||||||
@ -1711,12 +1704,12 @@ msgstr ""
|
|||||||
"Извините, на сегодня нет никаких советов:\n"
|
"Извините, на сегодня нет никаких советов:\n"
|
||||||
"%s"
|
"%s"
|
||||||
|
|
||||||
#: ../js/ui/wanda.js:121
|
#: ../js/ui/wanda.js:123
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s the Oracle says"
|
msgid "%s the Oracle says"
|
||||||
msgstr "Оракул говорит: «%s»"
|
msgstr "Оракул говорит: «%s»"
|
||||||
|
|
||||||
#: ../js/ui/wanda.js:162
|
#: ../js/ui/wanda.js:164
|
||||||
msgid "Your favorite Easter Egg"
|
msgid "Your favorite Easter Egg"
|
||||||
msgstr "Ваше любимое «пасхальное яйцо»"
|
msgstr "Ваше любимое «пасхальное яйцо»"
|
||||||
|
|
||||||
@ -1753,24 +1746,24 @@ msgstr[2] "%u входов"
|
|||||||
msgid "System Sounds"
|
msgid "System Sounds"
|
||||||
msgstr "Системные звуки"
|
msgstr "Системные звуки"
|
||||||
|
|
||||||
#: ../src/main.c:332
|
#: ../src/main.c:330
|
||||||
msgid "Print version"
|
msgid "Print version"
|
||||||
msgstr "Показать номер версии"
|
msgstr "Показать номер версии"
|
||||||
|
|
||||||
#: ../src/main.c:338
|
#: ../src/main.c:336
|
||||||
msgid "Mode used by GDM for login screen"
|
msgid "Mode used by GDM for login screen"
|
||||||
msgstr "Режим, используемый GDM для окна входа в систему"
|
msgstr "Режим, используемый GDM для окна входа в систему"
|
||||||
|
|
||||||
#: ../src/main.c:344
|
#: ../src/main.c:342
|
||||||
msgid "Use a specific mode, e.g. \"gdm\" for login screen"
|
msgid "Use a specific mode, e.g. \"gdm\" for login screen"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Использовать для экрана входа в систему определённый режим, например «gdm»"
|
"Использовать для экрана входа в систему определённый режим, например «gdm»"
|
||||||
|
|
||||||
#: ../src/main.c:350
|
#: ../src/main.c:348
|
||||||
msgid "List possible modes"
|
msgid "List possible modes"
|
||||||
msgstr "Список возможных режимов"
|
msgstr "Список возможных режимов"
|
||||||
|
|
||||||
#: ../src/shell-app.c:622
|
#: ../src/shell-app.c:621
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Failed to launch '%s'"
|
msgid "Failed to launch '%s'"
|
||||||
msgstr "Не удалось запустить «%s»"
|
msgstr "Не удалось запустить «%s»"
|
||||||
@ -1795,9 +1788,6 @@ msgstr "По умолчанию"
|
|||||||
msgid "Authentication dialog was dismissed by the user"
|
msgid "Authentication dialog was dismissed by the user"
|
||||||
msgstr "Пользователь отклонил диалог аутентификации"
|
msgstr "Пользователь отклонил диалог аутентификации"
|
||||||
|
|
||||||
#~ msgid "Switch Session"
|
|
||||||
#~ msgstr "Переключить сеанс"
|
|
||||||
|
|
||||||
#~ msgid "disabled OpenSearch providers"
|
#~ msgid "disabled OpenSearch providers"
|
||||||
#~ msgstr "отключённые провайдеры OpenSearch"
|
#~ msgstr "отключённые провайдеры OpenSearch"
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@ def show_version(option, opt_str, value, parser):
|
|||||||
def wait_for_dbus_name(wait_name):
|
def wait_for_dbus_name(wait_name):
|
||||||
loop = GLib.MainLoop()
|
loop = GLib.MainLoop()
|
||||||
|
|
||||||
def on_name_appeared(connection, name, new_owner, *args):
|
def on_name_appeared(connection, name, name_owner, *args):
|
||||||
if not (name == wait_name and new_owner != ''):
|
if not (name == wait_name and new_owner != ''):
|
||||||
return
|
return
|
||||||
loop.quit()
|
loop.quit()
|
||||||
@ -60,18 +60,13 @@ def start_perf_helper():
|
|||||||
wait_for_dbus_name (PERF_HELPER_NAME)
|
wait_for_dbus_name (PERF_HELPER_NAME)
|
||||||
|
|
||||||
def stop_perf_helper():
|
def stop_perf_helper():
|
||||||
bus = Gio.bus_get_sync(Gio.BusType.SESSION, None)
|
proxy = Gio.DBusProxy(g_bus_type=Gio.BusType.SESSION,
|
||||||
|
g_name=PERF_HELPER_NAME,
|
||||||
proxy = Gio.DBusProxy.new_sync(bus,
|
g_interface=PERF_HELPER_IFACE,
|
||||||
Gio.DBusProxyFlags.NONE,
|
g_object_path=PERF_HELPER_PATH)
|
||||||
None,
|
|
||||||
PERF_HELPER_NAME,
|
|
||||||
PERF_HELPER_PATH,
|
|
||||||
PERF_HELPER_IFACE,
|
|
||||||
None)
|
|
||||||
proxy.Exit()
|
proxy.Exit()
|
||||||
|
|
||||||
def start_shell(perf_output=None):
|
def start_shell(extra_args, perf_output=None):
|
||||||
# Set up environment
|
# Set up environment
|
||||||
env = dict(os.environ)
|
env = dict(os.environ)
|
||||||
env['SHELL_PERF_MODULE'] = options.perf
|
env['SHELL_PERF_MODULE'] = options.perf
|
||||||
@ -81,21 +76,19 @@ def start_shell(perf_output=None):
|
|||||||
env['SHELL_PERF_OUTPUT'] = perf_output
|
env['SHELL_PERF_OUTPUT'] = perf_output
|
||||||
|
|
||||||
self_dir = os.path.dirname(os.path.abspath(sys.argv[0]))
|
self_dir = os.path.dirname(os.path.abspath(sys.argv[0]))
|
||||||
args = []
|
|
||||||
args.append(os.path.join(self_dir, 'gnome-shell'))
|
args.append(os.path.join(self_dir, 'gnome-shell'))
|
||||||
|
# pass on any additional arguments
|
||||||
if options.replace:
|
args += extra_args
|
||||||
args.append('--replace')
|
|
||||||
|
|
||||||
return subprocess.Popen(args, env=env)
|
return subprocess.Popen(args, env=env)
|
||||||
|
|
||||||
def run_shell(perf_output=None):
|
def run_shell(args, perf_output=None):
|
||||||
# we do no additional supervision of gnome-shell,
|
# we do no additional supervision of gnome-shell,
|
||||||
# beyond that of wait
|
# beyond that of wait
|
||||||
# in particular, we don't kill the shell upon
|
# in particular, we don't kill the shell upon
|
||||||
# receving a KeyboardInterrupt, as we expect to be
|
# receving a KeyboardInterrupt, as we expect to be
|
||||||
# in the same process group
|
# in the same process group
|
||||||
shell = start_shell(perf_output=perf_output)
|
shell = start_shell(extra_args, perf_output=perf_output)
|
||||||
shell.wait()
|
shell.wait()
|
||||||
return shell.returncode == 0
|
return shell.returncode == 0
|
||||||
|
|
||||||
@ -180,7 +173,7 @@ def upload_performance_report(report_text):
|
|||||||
print "Performance report upload failed with status %d" % response.status
|
print "Performance report upload failed with status %d" % response.status
|
||||||
print response.read()
|
print response.read()
|
||||||
|
|
||||||
def run_performance_test():
|
def run_performance_test(args):
|
||||||
iters = options.perf_iters
|
iters = options.perf_iters
|
||||||
if options.perf_warmup:
|
if options.perf_warmup:
|
||||||
iters += 1
|
iters += 1
|
||||||
@ -199,7 +192,7 @@ def run_performance_test():
|
|||||||
# Run the performance test and collect the output as JSON
|
# Run the performance test and collect the output as JSON
|
||||||
normal_exit = False
|
normal_exit = False
|
||||||
try:
|
try:
|
||||||
normal_exit = run_shell(perf_output=output_file)
|
normal_exit = run_shell(args, perf_output=output_file)
|
||||||
except:
|
except:
|
||||||
stop_perf_helper()
|
stop_perf_helper()
|
||||||
raise
|
raise
|
||||||
@ -295,8 +288,7 @@ def run_performance_test():
|
|||||||
|
|
||||||
parser = optparse.OptionParser()
|
parser = optparse.OptionParser()
|
||||||
parser.add_option("", "--perf", metavar="PERF_MODULE",
|
parser.add_option("", "--perf", metavar="PERF_MODULE",
|
||||||
help="Specify the name of a performance module to run",
|
help="Specify the name of a performance module to run")
|
||||||
default="core")
|
|
||||||
parser.add_option("", "--perf-iters", type="int", metavar="ITERS",
|
parser.add_option("", "--perf-iters", type="int", metavar="ITERS",
|
||||||
help="Numbers of iterations of performance module to run",
|
help="Numbers of iterations of performance module to run",
|
||||||
default=1)
|
default=1)
|
||||||
@ -309,16 +301,9 @@ parser.add_option("", "--perf-upload", action="store_true",
|
|||||||
parser.add_option("", "--version", action="callback", callback=show_version,
|
parser.add_option("", "--version", action="callback", callback=show_version,
|
||||||
help="Display version and exit")
|
help="Display version and exit")
|
||||||
|
|
||||||
parser.add_option("-r", "--replace", action="store_true",
|
|
||||||
help="Replace the running window manager")
|
|
||||||
|
|
||||||
options, args = parser.parse_args()
|
options, args = parser.parse_args()
|
||||||
|
|
||||||
if args:
|
normal_exit = run_performance_test(args)
|
||||||
parser.print_usage()
|
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
normal_exit = run_performance_test()
|
|
||||||
if normal_exit:
|
if normal_exit:
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
else:
|
else:
|
||||||
|
@ -37,11 +37,10 @@
|
|||||||
|
|
||||||
#define ISO_3166_COUNTRY_CODES DATADIR "/zoneinfo/iso3166.tab"
|
#define ISO_3166_COUNTRY_CODES DATADIR "/zoneinfo/iso3166.tab"
|
||||||
|
|
||||||
static ShellCountryMobileProvider *country_mobile_provider_new (const char *country_code,
|
|
||||||
const gchar *country_name);
|
|
||||||
|
|
||||||
static GHashTable *
|
static GHashTable *
|
||||||
read_country_codes (const gchar *country_codes)
|
read_country_codes (void)
|
||||||
{
|
{
|
||||||
GHashTable *table;
|
GHashTable *table;
|
||||||
GIOChannel *channel;
|
GIOChannel *channel;
|
||||||
@ -49,21 +48,18 @@ read_country_codes (const gchar *country_codes)
|
|||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
GIOStatus status;
|
GIOStatus status;
|
||||||
|
|
||||||
channel = g_io_channel_new_file (country_codes, "r", &error);
|
channel = g_io_channel_new_file (ISO_3166_COUNTRY_CODES, "r", &error);
|
||||||
if (!channel) {
|
if (!channel) {
|
||||||
if (error) {
|
if (error) {
|
||||||
g_warning ("Could not read %s: %s", country_codes, error->message);
|
g_warning ("Could not read " ISO_3166_COUNTRY_CODES ": %s", error->message);
|
||||||
g_error_free (error);
|
g_error_free (error);
|
||||||
} else
|
} else
|
||||||
g_warning ("Could not read %s: Unknown error", country_codes);
|
g_warning ("Could not read " ISO_3166_COUNTRY_CODES ": Unknown error");
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
table = g_hash_table_new_full (g_str_hash,
|
table = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_free);
|
||||||
g_str_equal,
|
|
||||||
g_free,
|
|
||||||
(GDestroyNotify)shell_country_mobile_provider_unref);
|
|
||||||
buffer = g_string_sized_new (32);
|
buffer = g_string_sized_new (32);
|
||||||
|
|
||||||
status = G_IO_STATUS_NORMAL;
|
status = G_IO_STATUS_NORMAL;
|
||||||
@ -73,7 +69,6 @@ read_country_codes (const gchar *country_codes)
|
|||||||
switch (status) {
|
switch (status) {
|
||||||
case G_IO_STATUS_NORMAL:
|
case G_IO_STATUS_NORMAL:
|
||||||
if (buffer->str[0] != '#') {
|
if (buffer->str[0] != '#') {
|
||||||
ShellCountryMobileProvider *country_provider;
|
|
||||||
char **pieces;
|
char **pieces;
|
||||||
|
|
||||||
pieces = g_strsplit (buffer->str, "\t", 2);
|
pieces = g_strsplit (buffer->str, "\t", 2);
|
||||||
@ -85,8 +80,7 @@ read_country_codes (const gchar *country_codes)
|
|||||||
pieces[1] = g_strdup (_("United Kingdom"));
|
pieces[1] = g_strdup (_("United Kingdom"));
|
||||||
}
|
}
|
||||||
|
|
||||||
country_provider = country_mobile_provider_new (pieces[0], pieces[1]);
|
g_hash_table_insert (table, pieces[0], pieces[1]);
|
||||||
g_hash_table_insert (table, pieces[0], country_provider);
|
|
||||||
g_free (pieces);
|
g_free (pieces);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -123,6 +117,7 @@ typedef enum {
|
|||||||
} MobileContextState;
|
} MobileContextState;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
GHashTable *country_codes;
|
||||||
GHashTable *table;
|
GHashTable *table;
|
||||||
|
|
||||||
char *current_country;
|
char *current_country;
|
||||||
@ -281,86 +276,6 @@ shell_mobile_provider_get_type (void)
|
|||||||
return type;
|
return type;
|
||||||
}
|
}
|
||||||
|
|
||||||
static ShellCountryMobileProvider *
|
|
||||||
country_mobile_provider_new (const char *country_code,
|
|
||||||
const gchar *country_name)
|
|
||||||
{
|
|
||||||
ShellCountryMobileProvider *country_provider;
|
|
||||||
|
|
||||||
country_provider = g_slice_new0 (ShellCountryMobileProvider);
|
|
||||||
country_provider->refs = 1;
|
|
||||||
country_provider->country_code = g_strdup (country_code);
|
|
||||||
country_provider->country_name = g_strdup (country_name);
|
|
||||||
return country_provider;
|
|
||||||
}
|
|
||||||
|
|
||||||
ShellCountryMobileProvider *
|
|
||||||
shell_country_mobile_provider_ref (ShellCountryMobileProvider *country_provider)
|
|
||||||
{
|
|
||||||
country_provider->refs++;
|
|
||||||
|
|
||||||
return country_provider;
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
shell_country_mobile_provider_unref (ShellCountryMobileProvider *country_provider)
|
|
||||||
{
|
|
||||||
if (--country_provider->refs == 0) {
|
|
||||||
g_free (country_provider->country_code);
|
|
||||||
g_free (country_provider->country_name);
|
|
||||||
g_slist_free_full (country_provider->providers,
|
|
||||||
(GDestroyNotify) shell_mobile_provider_unref);
|
|
||||||
g_slice_free (ShellCountryMobileProvider, country_provider);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* shell_country_mobile_provider_get_country_code:
|
|
||||||
*
|
|
||||||
* Returns: (transfer none): the code of the country.
|
|
||||||
*/
|
|
||||||
const gchar *
|
|
||||||
shell_country_mobile_provider_get_country_code (ShellCountryMobileProvider *country_provider)
|
|
||||||
{
|
|
||||||
return country_provider->country_code;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* shell_country_mobile_provider_get_country_name:
|
|
||||||
*
|
|
||||||
* Returns: (transfer none): the name of the country.
|
|
||||||
*/
|
|
||||||
const gchar *
|
|
||||||
shell_country_mobile_provider_get_country_name (ShellCountryMobileProvider *country_provider)
|
|
||||||
{
|
|
||||||
return country_provider->country_name;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* shell_country_mobile_provider_get_providers:
|
|
||||||
*
|
|
||||||
* Returns: (element-type Shell.MobileProvider) (transfer none): the
|
|
||||||
* list of #ShellMobileProvider this country exposes.
|
|
||||||
*/
|
|
||||||
GSList *
|
|
||||||
shell_country_mobile_provider_get_providers (ShellCountryMobileProvider *country_provider)
|
|
||||||
{
|
|
||||||
return country_provider->providers;
|
|
||||||
}
|
|
||||||
|
|
||||||
GType
|
|
||||||
shell_country_mobile_provider_get_type (void)
|
|
||||||
{
|
|
||||||
static GType type = 0;
|
|
||||||
|
|
||||||
if (G_UNLIKELY (type == 0)) {
|
|
||||||
type = g_boxed_type_register_static ("ShellCountryMobileProvider",
|
|
||||||
(GBoxedCopyFunc) shell_country_mobile_provider_ref,
|
|
||||||
(GBoxedFreeFunc) shell_country_mobile_provider_unref);
|
|
||||||
}
|
|
||||||
return type;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
provider_list_free (gpointer data)
|
provider_list_free (gpointer data)
|
||||||
{
|
{
|
||||||
@ -395,16 +310,14 @@ parser_toplevel_start (MobileParser *parser,
|
|||||||
for (i = 0; attribute_names && attribute_names[i]; i++) {
|
for (i = 0; attribute_names && attribute_names[i]; i++) {
|
||||||
if (!strcmp (attribute_names[i], "code")) {
|
if (!strcmp (attribute_names[i], "code")) {
|
||||||
char *country_code;
|
char *country_code;
|
||||||
ShellCountryMobileProvider *country_provider;
|
char *country;
|
||||||
|
|
||||||
country_code = g_ascii_strup (attribute_values[i], -1);
|
country_code = g_ascii_strup (attribute_values[i], -1);
|
||||||
country_provider = g_hash_table_lookup (parser->table, country_code);
|
country = g_hash_table_lookup (parser->country_codes, country_code);
|
||||||
/* Ensure we have a country provider for this country code */
|
if (country) {
|
||||||
if (!country_provider) {
|
parser->current_country = g_strdup (country);
|
||||||
g_warning ("%s: adding providers for unknown country '%s'", __func__, country_code);
|
g_free (country_code);
|
||||||
country_provider = country_mobile_provider_new (country_code, NULL);
|
} else
|
||||||
g_hash_table_insert (parser->table, country_code, country_provider);
|
|
||||||
}
|
|
||||||
parser->current_country = country_code;
|
parser->current_country = country_code;
|
||||||
|
|
||||||
parser->state = PARSER_COUNTRY;
|
parser->state = PARSER_COUNTRY;
|
||||||
@ -542,13 +455,7 @@ parser_country_end (MobileParser *parser,
|
|||||||
const char *name)
|
const char *name)
|
||||||
{
|
{
|
||||||
if (!strcmp (name, "country")) {
|
if (!strcmp (name, "country")) {
|
||||||
ShellCountryMobileProvider *country_provider;
|
g_hash_table_insert (parser->table, parser->current_country, parser->current_providers);
|
||||||
|
|
||||||
country_provider = g_hash_table_lookup (parser->table, parser->current_country);
|
|
||||||
if (country_provider)
|
|
||||||
/* Store providers for this country */
|
|
||||||
country_provider->providers = parser->current_providers;
|
|
||||||
|
|
||||||
parser->current_country = NULL;
|
parser->current_country = NULL;
|
||||||
parser->current_providers = NULL;
|
parser->current_providers = NULL;
|
||||||
parser->text_buffer = NULL;
|
parser->text_buffer = NULL;
|
||||||
@ -709,16 +616,15 @@ static const GMarkupParser mobile_parser = {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_mobile_providers_parse:
|
* shell_mobile_providers_parse:
|
||||||
* @country_codes: (allow-none) File with the list of country codes.
|
* @out_ccs: (out) (allow-none): (element-type utf8 utf8): a #GHashTable containing
|
||||||
* @service_providers: (allow-none) File with the list of service providers.
|
* country codes
|
||||||
*
|
*
|
||||||
* Returns: (element-type utf8 Shell.CountryMobileProvider) (transfer full): a
|
* Returns: (element-type utf8 GList) (transfer container): a
|
||||||
* hash table where keys are country names #gchar and values are #ShellCountryMobileProvider.
|
* hash table where keys are country names #gchar, values are a #GSList
|
||||||
* Everything is destroyed with g_hash_table_destroy().
|
* of #ShellMobileProvider. Everything is destroyed with g_hash_table_destroy().
|
||||||
*/
|
*/
|
||||||
GHashTable *
|
GHashTable *
|
||||||
shell_mobile_providers_parse (const gchar *country_codes,
|
shell_mobile_providers_parse (GHashTable **out_ccs)
|
||||||
const gchar *service_providers)
|
|
||||||
{
|
{
|
||||||
GMarkupParseContext *ctx;
|
GMarkupParseContext *ctx;
|
||||||
GIOChannel *channel;
|
GIOChannel *channel;
|
||||||
@ -728,29 +634,24 @@ shell_mobile_providers_parse (const gchar *country_codes,
|
|||||||
GIOStatus status;
|
GIOStatus status;
|
||||||
gsize len = 0;
|
gsize len = 0;
|
||||||
|
|
||||||
/* Use default paths if none given */
|
|
||||||
if (!country_codes)
|
|
||||||
country_codes = ISO_3166_COUNTRY_CODES;
|
|
||||||
if (!service_providers)
|
|
||||||
service_providers = MOBILE_BROADBAND_PROVIDER_INFO;
|
|
||||||
|
|
||||||
memset (&parser, 0, sizeof (MobileParser));
|
memset (&parser, 0, sizeof (MobileParser));
|
||||||
|
|
||||||
parser.table = read_country_codes (country_codes);
|
parser.country_codes = read_country_codes ();
|
||||||
if (!parser.table)
|
if (!parser.country_codes)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
channel = g_io_channel_new_file (service_providers, "r", &error);
|
channel = g_io_channel_new_file (MOBILE_BROADBAND_PROVIDER_INFO, "r", &error);
|
||||||
if (!channel) {
|
if (!channel) {
|
||||||
if (error) {
|
if (error) {
|
||||||
g_warning ("Could not read %s: %s", service_providers, error->message);
|
g_warning ("Could not read " MOBILE_BROADBAND_PROVIDER_INFO ": %s", error->message);
|
||||||
g_error_free (error);
|
g_error_free (error);
|
||||||
} else
|
} else
|
||||||
g_warning ("Could not read %s: Unknown error", service_providers);
|
g_warning ("Could not read " MOBILE_BROADBAND_PROVIDER_INFO ": Unknown error");
|
||||||
|
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
parser.table = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, provider_list_free);
|
||||||
parser.state = PARSER_TOPLEVEL;
|
parser.state = PARSER_TOPLEVEL;
|
||||||
|
|
||||||
ctx = g_markup_parse_context_new (&mobile_parser, 0, &parser, NULL);
|
ctx = g_markup_parse_context_new (&mobile_parser, 0, &parser, NULL);
|
||||||
@ -796,6 +697,12 @@ shell_mobile_providers_parse (const gchar *country_codes,
|
|||||||
g_free (parser.text_buffer);
|
g_free (parser.text_buffer);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
|
if (parser.country_codes) {
|
||||||
|
if (out_ccs)
|
||||||
|
*out_ccs = parser.country_codes;
|
||||||
|
else
|
||||||
|
g_hash_table_destroy (parser.country_codes);
|
||||||
|
}
|
||||||
|
|
||||||
return parser.table;
|
return parser.table;
|
||||||
}
|
}
|
||||||
@ -837,14 +744,9 @@ dump_gsm (ShellMobileAccessMethod *method)
|
|||||||
static void
|
static void
|
||||||
dump_country (gpointer key, gpointer value, gpointer user_data)
|
dump_country (gpointer key, gpointer value, gpointer user_data)
|
||||||
{
|
{
|
||||||
GSList *miter, *citer;
|
GSList *citer, *miter;
|
||||||
ShellCountryMobileProvider *country_provider = value;
|
|
||||||
|
|
||||||
g_print ("Country: %s (%s)\n",
|
for (citer = value; citer; citer = g_slist_next (citer)) {
|
||||||
country_provider->country_code,
|
|
||||||
country_provider->country_name);
|
|
||||||
|
|
||||||
for (citer = country_provider->providers; citer; citer = g_slist_next (citer)) {
|
|
||||||
ShellMobileProvider *provider = citer->data;
|
ShellMobileProvider *provider = citer->data;
|
||||||
|
|
||||||
g_print ("Provider: %s (%s)\n", provider->name, (const char *) key);
|
g_print ("Provider: %s (%s)\n", provider->name, (const char *) key);
|
||||||
@ -877,10 +779,10 @@ dump_country (gpointer key, gpointer value, gpointer user_data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
shell_mobile_providers_dump (GHashTable *country_providers)
|
shell_mobile_providers_dump (GHashTable *providers)
|
||||||
{
|
{
|
||||||
g_return_if_fail (country_providers != NULL);
|
g_return_if_fail (providers != NULL);
|
||||||
g_hash_table_foreach (country_providers, dump_country, NULL);
|
g_hash_table_foreach (providers, dump_country, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* All the following don't exist in nm-applet, because C doesn't need
|
/* All the following don't exist in nm-applet, because C doesn't need
|
||||||
|
@ -76,19 +76,10 @@ typedef struct {
|
|||||||
gint refs;
|
gint refs;
|
||||||
} ShellMobileProvider;
|
} ShellMobileProvider;
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
char *country_code;
|
|
||||||
char *country_name;
|
|
||||||
GSList *providers;
|
|
||||||
|
|
||||||
gint refs;
|
|
||||||
} ShellCountryMobileProvider;
|
|
||||||
|
|
||||||
|
|
||||||
GType shell_gsm_mcc_mnc_get_type (void); /* added in porting */
|
GType shell_gsm_mcc_mnc_get_type (void); /* added in porting */
|
||||||
GType shell_mobile_access_method_get_type (void);
|
|
||||||
GType shell_mobile_provider_get_type (void);
|
GType shell_mobile_provider_get_type (void);
|
||||||
GType shell_country_mobile_provider_get_type (void);
|
GType shell_mobile_access_method_get_type (void);
|
||||||
|
|
||||||
ShellMobileProvider *shell_mobile_provider_ref (ShellMobileProvider *provider);
|
ShellMobileProvider *shell_mobile_provider_ref (ShellMobileProvider *provider);
|
||||||
void shell_mobile_provider_unref (ShellMobileProvider *provider);
|
void shell_mobile_provider_unref (ShellMobileProvider *provider);
|
||||||
@ -98,14 +89,8 @@ GSList * shell_mobile_provider_get_cdma_sid (ShellMobileProvider *pr
|
|||||||
ShellMobileAccessMethod *shell_mobile_access_method_ref (ShellMobileAccessMethod *method);
|
ShellMobileAccessMethod *shell_mobile_access_method_ref (ShellMobileAccessMethod *method);
|
||||||
void shell_mobile_access_method_unref (ShellMobileAccessMethod *method);
|
void shell_mobile_access_method_unref (ShellMobileAccessMethod *method);
|
||||||
|
|
||||||
ShellCountryMobileProvider *shell_country_mobile_provider_ref (ShellCountryMobileProvider *country_provider);
|
GHashTable *shell_mobile_providers_parse (GHashTable **out_ccs);
|
||||||
void shell_country_mobile_provider_unref (ShellCountryMobileProvider *country_provider);
|
|
||||||
const gchar *shell_country_mobile_provider_get_country_code (ShellCountryMobileProvider *country_provider);
|
|
||||||
const gchar *shell_country_mobile_provider_get_country_name (ShellCountryMobileProvider *country_provider);
|
|
||||||
GSList *shell_country_mobile_provider_get_providers (ShellCountryMobileProvider *country_provider);
|
|
||||||
|
|
||||||
GHashTable *shell_mobile_providers_parse (const gchar *country_codes,
|
void shell_mobile_providers_dump (GHashTable *providers);
|
||||||
const gchar *service_providers);
|
|
||||||
void shell_mobile_providers_dump (GHashTable *country_providers);
|
|
||||||
|
|
||||||
#endif /* SHELL_MOBILE_PROVIDERS_H */
|
#endif /* SHELL_MOBILE_PROVIDERS_H */
|
||||||
|
@ -65,10 +65,6 @@
|
|||||||
#include "st-clipboard.h"
|
#include "st-clipboard.h"
|
||||||
#include "st-private.h"
|
#include "st-private.h"
|
||||||
|
|
||||||
#include <clutter/x11/clutter-x11.h>
|
|
||||||
#include <X11/Xlib.h>
|
|
||||||
#include <X11/cursorfont.h>
|
|
||||||
|
|
||||||
#include "st-widget-accessible.h"
|
#include "st-widget-accessible.h"
|
||||||
|
|
||||||
#define HAS_FOCUS(actor) (clutter_actor_get_stage (actor) && clutter_stage_get_key_focus ((ClutterStage *) clutter_actor_get_stage (actor)) == actor)
|
#define HAS_FOCUS(actor) (clutter_actor_get_stage (actor) && clutter_stage_get_key_focus ((ClutterStage *) clutter_actor_get_stage (actor)) == actor)
|
||||||
@ -617,38 +613,6 @@ st_entry_key_focus_in (ClutterActor *actor)
|
|||||||
clutter_actor_grab_key_focus (priv->entry);
|
clutter_actor_grab_key_focus (priv->entry);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
st_entry_set_cursor (StEntry *entry,
|
|
||||||
gboolean use_ibeam)
|
|
||||||
{
|
|
||||||
Display *dpy;
|
|
||||||
ClutterActor *stage, *actor = CLUTTER_ACTOR (entry);
|
|
||||||
Window wid;
|
|
||||||
static Cursor ibeam = None;
|
|
||||||
|
|
||||||
dpy = clutter_x11_get_default_display ();
|
|
||||||
stage = clutter_actor_get_stage (actor);
|
|
||||||
wid = clutter_x11_get_stage_window (CLUTTER_STAGE (stage));
|
|
||||||
|
|
||||||
if (ibeam == None)
|
|
||||||
ibeam = XCreateFontCursor (dpy, XC_xterm);
|
|
||||||
|
|
||||||
if (use_ibeam)
|
|
||||||
XDefineCursor (dpy, wid, ibeam);
|
|
||||||
else
|
|
||||||
XUndefineCursor (dpy, wid);
|
|
||||||
}
|
|
||||||
|
|
||||||
static gboolean
|
|
||||||
st_entry_crossing_event (ClutterActor *actor,
|
|
||||||
ClutterCrossingEvent *event)
|
|
||||||
{
|
|
||||||
if (event->source == ST_ENTRY (actor)->priv->entry && event->related != NULL)
|
|
||||||
st_entry_set_cursor (ST_ENTRY (actor), (event->type == CLUTTER_ENTER));
|
|
||||||
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
st_entry_class_init (StEntryClass *klass)
|
st_entry_class_init (StEntryClass *klass)
|
||||||
{
|
{
|
||||||
@ -671,9 +635,6 @@ st_entry_class_init (StEntryClass *klass)
|
|||||||
actor_class->key_press_event = st_entry_key_press_event;
|
actor_class->key_press_event = st_entry_key_press_event;
|
||||||
actor_class->key_focus_in = st_entry_key_focus_in;
|
actor_class->key_focus_in = st_entry_key_focus_in;
|
||||||
|
|
||||||
actor_class->enter_event = st_entry_crossing_event;
|
|
||||||
actor_class->leave_event = st_entry_crossing_event;
|
|
||||||
|
|
||||||
widget_class->style_changed = st_entry_style_changed;
|
widget_class->style_changed = st_entry_style_changed;
|
||||||
widget_class->navigate_focus = st_entry_navigate_focus;
|
widget_class->navigate_focus = st_entry_navigate_focus;
|
||||||
widget_class->get_accessible_type = st_entry_accessible_get_type;
|
widget_class->get_accessible_type = st_entry_accessible_get_type;
|
||||||
|
@ -450,26 +450,26 @@ static gboolean
|
|||||||
string_in_list (GString *stryng,
|
string_in_list (GString *stryng,
|
||||||
const char *list)
|
const char *list)
|
||||||
{
|
{
|
||||||
char *cur;
|
const char *cur;
|
||||||
char *l = g_strdup (list);
|
|
||||||
char *temp;
|
|
||||||
gboolean found = FALSE;
|
|
||||||
|
|
||||||
cur = strtok_r (l, " \t\f\r\n", &temp);
|
for (cur = list; *cur;)
|
||||||
while (cur != NULL)
|
|
||||||
{
|
{
|
||||||
if (!strqcmp (cur, stryng->str, stryng->len))
|
while (*cur && cr_utils_is_white_space (*cur))
|
||||||
|
cur++;
|
||||||
|
|
||||||
|
if (strncmp (cur, stryng->str, stryng->len) == 0)
|
||||||
{
|
{
|
||||||
found = TRUE;
|
cur += stryng->len;
|
||||||
goto out;
|
if ((!*cur) || cr_utils_is_white_space (*cur))
|
||||||
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
cur = strtok_r (NULL, " \t\f\r\n", &temp);
|
/* skip to next whitespace character */
|
||||||
|
while (*cur && !cr_utils_is_white_space (*cur))
|
||||||
|
cur++;
|
||||||
}
|
}
|
||||||
|
|
||||||
out:
|
return FALSE;
|
||||||
g_free (l);
|
|
||||||
return found;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
@ -18,7 +18,6 @@ TEST_JS = \
|
|||||||
interactive/scrolling.js \
|
interactive/scrolling.js \
|
||||||
interactive/scroll-view-sizing.js \
|
interactive/scroll-view-sizing.js \
|
||||||
interactive/table.js \
|
interactive/table.js \
|
||||||
interactive/test-title.js \
|
|
||||||
interactive/transitions.js \
|
interactive/transitions.js \
|
||||||
testcommon/100-200.svg \
|
testcommon/100-200.svg \
|
||||||
testcommon/200-100.svg \
|
testcommon/200-100.svg \
|
||||||
@ -26,14 +25,11 @@ TEST_JS = \
|
|||||||
testcommon/border-image.png \
|
testcommon/border-image.png \
|
||||||
testcommon/face-plain.png \
|
testcommon/face-plain.png \
|
||||||
testcommon/ui.js \
|
testcommon/ui.js \
|
||||||
testcommon/iso3166-test.tab \
|
|
||||||
testcommon/serviceproviders-test.xml \
|
|
||||||
unit/format.js \
|
unit/format.js \
|
||||||
unit/insertSorted.js \
|
unit/insertSorted.js \
|
||||||
unit/markup.js \
|
unit/markup.js \
|
||||||
unit/jsParse.js \
|
unit/jsParse.js \
|
||||||
unit/url.js \
|
unit/url.js
|
||||||
unit/mobileProviders.js
|
|
||||||
EXTRA_DIST += $(TEST_JS)
|
EXTRA_DIST += $(TEST_JS)
|
||||||
|
|
||||||
TEST_MISC = \
|
TEST_MISC = \
|
||||||
|
30
tests/interactive/center-layout.js
Normal file
30
tests/interactive/center-layout.js
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
|
|
||||||
|
const Clutter = imports.gi.Clutter;
|
||||||
|
const St = imports.gi.St;
|
||||||
|
|
||||||
|
const CenterLayout = imports.ui.centerLayout;
|
||||||
|
const UI = imports.testcommon.ui;
|
||||||
|
|
||||||
|
function test() {
|
||||||
|
let stage = new Clutter.Stage({ user_resizable: true });
|
||||||
|
UI.init(stage);
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
let container = new St.Widget({ style: 'border: 2px solid black;',
|
||||||
|
layout_manager: new CenterLayout.CenterLayout() });
|
||||||
|
container.add_constraint(new Clutter.BindConstraint({ coordinate: Clutter.BindCoordinate.SIZE, source: stage }));
|
||||||
|
stage.add_actor(container);
|
||||||
|
|
||||||
|
let left = new Clutter.Actor({ background_color: Clutter.Color.get_static(Clutter.StaticColor.RED), width: 300 });
|
||||||
|
let center = new Clutter.Actor({ background_color: Clutter.Color.get_static(Clutter.StaticColor.BLUE), width: 100 });
|
||||||
|
let right = new Clutter.Actor({ background_color: Clutter.Color.get_static(Clutter.StaticColor.YELLOW), width: 200 });
|
||||||
|
|
||||||
|
container.add_actor(left);
|
||||||
|
container.add_actor(center);
|
||||||
|
container.add_actor(right);
|
||||||
|
|
||||||
|
UI.main(stage);
|
||||||
|
}
|
||||||
|
test();
|
@ -1,3 +0,0 @@
|
|||||||
# Test country list
|
|
||||||
ES Spain
|
|
||||||
US United States
|
|
@ -1,44 +0,0 @@
|
|||||||
<?xml version="1.0"?>
|
|
||||||
|
|
||||||
<!-- -*- Mode: XML; tab-width: 2; indent-tabs-mode: t; c-basic-offset: 2 -*- -->
|
|
||||||
|
|
||||||
<!DOCTYPE serviceproviders SYSTEM "serviceproviders.2.dtd">
|
|
||||||
|
|
||||||
<serviceproviders format="2.0">
|
|
||||||
|
|
||||||
<!-- United States -->
|
|
||||||
<country code="us">
|
|
||||||
<provider>
|
|
||||||
<name>AT&T</name>
|
|
||||||
<gsm>
|
|
||||||
<network-id mcc="310" mnc="038"/>
|
|
||||||
<network-id mcc="310" mnc="090"/>
|
|
||||||
<network-id mcc="310" mnc="150"/>
|
|
||||||
</gsm>
|
|
||||||
</provider>
|
|
||||||
<provider>
|
|
||||||
<name>Verizon</name>
|
|
||||||
<gsm>
|
|
||||||
<network-id mcc="310" mnc="995"/>
|
|
||||||
<network-id mcc="311" mnc="480"/>
|
|
||||||
</gsm>
|
|
||||||
<cdma>
|
|
||||||
<sid value="2"/>
|
|
||||||
<sid value="4"/>
|
|
||||||
<sid value="5"/>
|
|
||||||
</cdma>
|
|
||||||
</provider>
|
|
||||||
</country>
|
|
||||||
|
|
||||||
<!-- Spain -->
|
|
||||||
<country code="es">
|
|
||||||
<provider>
|
|
||||||
<name>Movistar (Telefónica)</name>
|
|
||||||
<gsm>
|
|
||||||
<network-id mcc="214" mnc="05"/>
|
|
||||||
<network-id mcc="214" mnc="07"/>
|
|
||||||
</gsm>
|
|
||||||
</provider>
|
|
||||||
</country>
|
|
||||||
|
|
||||||
</serviceproviders>
|
|
@ -1,78 +0,0 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
|
||||||
|
|
||||||
const GLib = imports.gi.GLib;
|
|
||||||
const Shell = imports.gi.Shell;
|
|
||||||
const JsUnit = imports.jsUnit;
|
|
||||||
const ModemManager = imports.misc.modemManager;
|
|
||||||
const Environment = imports.ui.environment;
|
|
||||||
|
|
||||||
Environment.init();
|
|
||||||
|
|
||||||
// Load test providers table
|
|
||||||
let countrycodesPath = GLib.getenv("GNOME_SHELL_TESTSDIR") + "/testcommon/iso3166-test.tab";
|
|
||||||
let serviceprovidersPath = GLib.getenv("GNOME_SHELL_TESTSDIR") + "/testcommon/serviceproviders-test.xml";
|
|
||||||
let providersTable = Shell.mobile_providers_parse(countrycodesPath, serviceprovidersPath);
|
|
||||||
|
|
||||||
function assertCountryFound(country_code, expected_country_name) {
|
|
||||||
let country = providersTable[country_code];
|
|
||||||
JsUnit.assertNotUndefined(country);
|
|
||||||
JsUnit.assertEquals(country.get_country_name(), expected_country_name);
|
|
||||||
}
|
|
||||||
|
|
||||||
function assertCountryNotFound(country_code) {
|
|
||||||
let country = providersTable[country_code];
|
|
||||||
JsUnit.assertUndefined(country);
|
|
||||||
}
|
|
||||||
|
|
||||||
function assertProviderFoundForMCCMNC(mccmnc, expected_provider_name) {
|
|
||||||
let provider_name = ModemManager.findProviderForMCCMNC(providersTable, mccmnc);
|
|
||||||
JsUnit.assertEquals(provider_name, expected_provider_name);
|
|
||||||
}
|
|
||||||
|
|
||||||
function assertProviderNotFoundForMCCMNC(mccmnc) {
|
|
||||||
let provider_name = ModemManager.findProviderForMCCMNC(providersTable, mccmnc);
|
|
||||||
JsUnit.assertNull(provider_name);
|
|
||||||
}
|
|
||||||
|
|
||||||
function assertProviderFoundForSid(sid, expected_provider_name) {
|
|
||||||
let provider_name = ModemManager.findProviderForSid(providersTable, sid);
|
|
||||||
JsUnit.assertEquals(provider_name, expected_provider_name);
|
|
||||||
}
|
|
||||||
|
|
||||||
function assertProviderNotFoundForSid(sid) {
|
|
||||||
let provider_name = ModemManager.findProviderForSid(providersTable, sid);
|
|
||||||
JsUnit.assertNull(provider_name);
|
|
||||||
}
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Both 'US' and 'ES' country info should be loaded
|
|
||||||
assertCountryFound("ES", "Spain");
|
|
||||||
assertCountryFound("US", "United States");
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Country info for 'FR' not given
|
|
||||||
assertCountryNotFound("FR");
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Ensure operator names are found for the given MCC/MNC codes
|
|
||||||
assertProviderFoundForMCCMNC("21405", "Movistar (Telefónica)");
|
|
||||||
assertProviderFoundForMCCMNC("21407", "Movistar (Telefónica)");
|
|
||||||
assertProviderFoundForMCCMNC("310038", "AT&T");
|
|
||||||
assertProviderFoundForMCCMNC("310090", "AT&T");
|
|
||||||
assertProviderFoundForMCCMNC("310150", "AT&T");
|
|
||||||
assertProviderFoundForMCCMNC("310995", "Verizon");
|
|
||||||
assertProviderFoundForMCCMNC("311480", "Verizon");
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Ensure NULL is given for unexpected MCC/MNC codes
|
|
||||||
assertProviderNotFoundForMCCMNC("12345");
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Ensure operator names are found for the given SID codes
|
|
||||||
assertProviderFoundForSid(2, "Verizon");
|
|
||||||
assertProviderFoundForSid(4, "Verizon");
|
|
||||||
assertProviderFoundForSid(5, "Verizon");
|
|
||||||
|
|
||||||
// TEST:
|
|
||||||
// * Ensure NULL is given for unexpected SID codes
|
|
||||||
assertProviderNotFoundForSid(1);
|
|
Reference in New Issue
Block a user