Compare commits
19 Commits
gbsneto/co
...
wip/hadess
Author | SHA1 | Date | |
---|---|---|---|
752b1df659 | |||
366b06716d | |||
4d47b16d33 | |||
6526e9edf6 | |||
055c007ac2 | |||
43cf466d09 | |||
6965781d59 | |||
80680803aa | |||
51601f3ead | |||
b25a73c243 | |||
d0690c3952 | |||
f2466caef3 | |||
b1d22d2058 | |||
6f7e5976e2 | |||
29543f369f | |||
a144a1c76d | |||
d91927674d | |||
d12cd12e1b | |||
caa50dc1a3 |
@ -16,8 +16,14 @@ run_eslint() {
|
|||||||
ARGS_LEGACY='--config lint/eslintrc-legacy.json'
|
ARGS_LEGACY='--config lint/eslintrc-legacy.json'
|
||||||
|
|
||||||
local extra_args=ARGS_$1
|
local extra_args=ARGS_$1
|
||||||
local output=OUTPUT_$1
|
local output_var=OUTPUT_$1
|
||||||
eslint -f unix ${!extra_args} -o ${!output} js
|
local output=${!output_var}
|
||||||
|
|
||||||
|
# ensure output exists even if eslint doesn't report any errors
|
||||||
|
mkdir -p $(dirname $output)
|
||||||
|
touch $output
|
||||||
|
|
||||||
|
eslint -f unix ${!extra_args} -o $output js
|
||||||
}
|
}
|
||||||
|
|
||||||
list_commit_range_additions() {
|
list_commit_range_additions() {
|
||||||
@ -70,10 +76,13 @@ create_common() {
|
|||||||
# non-legacy style just yet ...
|
# non-legacy style just yet ...
|
||||||
unset CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
unset CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
||||||
|
|
||||||
if [ "$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" ]; then
|
REMOTE=${1:-$CI_MERGE_REQUEST_PROJECT_URL.git}
|
||||||
git fetch $CI_MERGE_REQUEST_PROJECT_URL.git $CI_MERGE_REQUEST_TARGET_BRANCH_NAME
|
BRANCH_NAME=${2:-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME}
|
||||||
|
|
||||||
|
if [ "$BRANCH_NAME" ]; then
|
||||||
|
git fetch $REMOTE $BRANCH_NAME
|
||||||
branch_point=$(git merge-base HEAD FETCH_HEAD)
|
branch_point=$(git merge-base HEAD FETCH_HEAD)
|
||||||
commit_range=$branch_point...$CI_COMMIT_SHA
|
commit_range=$branch_point...HEAD
|
||||||
|
|
||||||
list_commit_range_additions $commit_range > $LINE_CHANGES
|
list_commit_range_additions $commit_range > $LINE_CHANGES
|
||||||
|
|
||||||
@ -96,7 +105,7 @@ if ! is_empty $OUTPUT_FINAL; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Just show the report and succeed when not testing a MR
|
# Just show the report and succeed when not testing a MR
|
||||||
if [ -z "$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" ]; then
|
if [ -z "$BRANCH_NAME" ]; then
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -50,7 +50,7 @@
|
|||||||
</description>
|
</description>
|
||||||
</key>
|
</key>
|
||||||
<key name="favorite-apps" type="as">
|
<key name="favorite-apps" type="as">
|
||||||
<default>[ 'epiphany.desktop', 'evolution.desktop', 'rhythmbox.desktop', 'shotwell.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Software.desktop' ]</default>
|
<default>[ 'epiphany.desktop', 'evolution.desktop', 'rhythmbox.desktop', 'org.gnome.Shotwell.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Software.desktop' ]</default>
|
||||||
<summary>List of desktop file IDs for favorite applications</summary>
|
<summary>List of desktop file IDs for favorite applications</summary>
|
||||||
<description>
|
<description>
|
||||||
The applications corresponding to these identifiers
|
The applications corresponding to these identifiers
|
||||||
|
@ -6,6 +6,7 @@ const { Clutter, GObject, Pango, Shell, St } = imports.gi;
|
|||||||
const Animation = imports.ui.animation;
|
const Animation = imports.ui.animation;
|
||||||
const Batch = imports.gdm.batch;
|
const Batch = imports.gdm.batch;
|
||||||
const GdmUtil = imports.gdm.util;
|
const GdmUtil = imports.gdm.util;
|
||||||
|
const Util = imports.misc.util;
|
||||||
const Params = imports.misc.params;
|
const Params = imports.misc.params;
|
||||||
const ShellEntry = imports.ui.shellEntry;
|
const ShellEntry = imports.ui.shellEntry;
|
||||||
const UserWidget = imports.ui.userWidget;
|
const UserWidget = imports.ui.userWidget;
|
||||||
@ -16,6 +17,10 @@ var DEFAULT_BUTTON_WELL_ANIMATION_TIME = 300;
|
|||||||
|
|
||||||
var MESSAGE_FADE_OUT_ANIMATION_TIME = 500;
|
var MESSAGE_FADE_OUT_ANIMATION_TIME = 500;
|
||||||
|
|
||||||
|
const WIGGLE_OFFSET = 6;
|
||||||
|
const WIGGLE_DURATION = 65;
|
||||||
|
const N_WIGGLES = 3;
|
||||||
|
|
||||||
var AuthPromptMode = {
|
var AuthPromptMode = {
|
||||||
UNLOCK_ONLY: 0,
|
UNLOCK_ONLY: 0,
|
||||||
UNLOCK_OR_LOG_IN: 1
|
UNLOCK_OR_LOG_IN: 1
|
||||||
@ -256,6 +261,12 @@ var AuthPrompt = GObject.registerClass({
|
|||||||
this.updateSensitivity(canRetry);
|
this.updateSensitivity(canRetry);
|
||||||
this.setActorInDefaultButtonWell(null);
|
this.setActorInDefaultButtonWell(null);
|
||||||
this.verificationStatus = AuthPromptStatus.VERIFICATION_FAILED;
|
this.verificationStatus = AuthPromptStatus.VERIFICATION_FAILED;
|
||||||
|
|
||||||
|
Util.wiggle(this._entry, {
|
||||||
|
offset: WIGGLE_OFFSET,
|
||||||
|
duration: WIGGLE_DURATION,
|
||||||
|
wiggleCount: N_WIGGLES,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
_onVerificationComplete() {
|
_onVerificationComplete() {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
/* exported findUrls, spawn, spawnCommandLine, spawnApp, trySpawnCommandLine,
|
/* exported findUrls, spawn, spawnCommandLine, spawnApp, trySpawnCommandLine,
|
||||||
formatTime, formatTimeSpan, createTimeLabel, insertSorted,
|
formatTime, formatTimeSpan, createTimeLabel, insertSorted,
|
||||||
makeCloseButton, ensureActorVisibleInScrollView */
|
makeCloseButton, ensureActorVisibleInScrollView, wiggle */
|
||||||
|
|
||||||
const { Clutter, Gio, GLib, GObject, Shell, St } = imports.gi;
|
const { Clutter, Gio, GLib, GObject, Shell, St } = imports.gi;
|
||||||
const Gettext = imports.gettext;
|
const Gettext = imports.gettext;
|
||||||
@ -429,3 +429,37 @@ function ensureActorVisibleInScrollView(scrollView, actor) {
|
|||||||
duration: SCROLL_TIME
|
duration: SCROLL_TIME
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function wiggle(actor, params) {
|
||||||
|
params = Params.parse(params, {
|
||||||
|
offset: 0,
|
||||||
|
duration: 0,
|
||||||
|
wiggleCount: 0,
|
||||||
|
});
|
||||||
|
actor.translation_x = 0;
|
||||||
|
|
||||||
|
// Accelerate before wiggling
|
||||||
|
actor.ease({
|
||||||
|
translation_x: -params.offset,
|
||||||
|
duration: params.duration,
|
||||||
|
mode: Clutter.AnimationMode.EASE_OUT_QUAD,
|
||||||
|
onComplete: () => {
|
||||||
|
// Wiggle
|
||||||
|
actor.ease({
|
||||||
|
translation_x: params.offset,
|
||||||
|
duration: params.duration,
|
||||||
|
mode: Clutter.AnimationMode.LINEAR,
|
||||||
|
repeatCount: params.wiggleCount,
|
||||||
|
autoReverse: true,
|
||||||
|
onComplete: () => {
|
||||||
|
// Decelerate and return to the original position
|
||||||
|
actor.ease({
|
||||||
|
translation_x: 0,
|
||||||
|
duration: params.duration,
|
||||||
|
mode: Clutter.AnimationMode.EASE_IN_QUAD,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
@ -2045,7 +2045,6 @@ var AppFolderPopup = GObject.registerClass({
|
|||||||
|
|
||||||
var AppIcon = GObject.registerClass({
|
var AppIcon = GObject.registerClass({
|
||||||
GTypeName: 'AppDisplay_AppIcon',
|
GTypeName: 'AppDisplay_AppIcon',
|
||||||
Implements: [Search.SearchResultInterface],
|
|
||||||
Signals: {
|
Signals: {
|
||||||
'menu-state-changed': { param_types: [GObject.TYPE_BOOLEAN] },
|
'menu-state-changed': { param_types: [GObject.TYPE_BOOLEAN] },
|
||||||
'sync-tooltip': {},
|
'sync-tooltip': {},
|
||||||
@ -2514,13 +2513,15 @@ var AppIconMenu = class AppIconMenu extends PopupMenu.PopupMenu {
|
|||||||
this._appendSeparator();
|
this._appendSeparator();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let wantsDiscreteGpu = appInfo.get_boolean("PreferRunOnDiscreteGPU") ||
|
||||||
|
appInfo.get_boolean("X-KDE-RunOnDiscreteGpu");
|
||||||
if (discreteGpuAvailable &&
|
if (discreteGpuAvailable &&
|
||||||
this._source.app.state == Shell.AppState.STOPPED &&
|
!wantsDiscreteGpu &&
|
||||||
!actions.includes('activate-discrete-gpu')) {
|
this._source.app.state == Shell.AppState.STOPPED) {
|
||||||
this._onDiscreteGpuMenuItem = this._appendMenuItem(_("Launch using Dedicated Graphics Card"));
|
this._onDiscreteGpuMenuItem = this._appendMenuItem(_("Launch using Dedicated Graphics Card"));
|
||||||
this._onDiscreteGpuMenuItem.connect('activate', () => {
|
this._onDiscreteGpuMenuItem.connect('activate', () => {
|
||||||
this._source.animateLaunch();
|
this._source.animateLaunch();
|
||||||
this._source.app.launch(0, -1, true);
|
this._source.app.launch(0, -1, Shell.AppGpuSelection.DISCRETE);
|
||||||
this.emit('activate-window', null);
|
this.emit('activate-window', null);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -2529,8 +2530,7 @@ var AppIconMenu = class AppIconMenu extends PopupMenu.PopupMenu {
|
|||||||
let action = actions[i];
|
let action = actions[i];
|
||||||
let item = this._appendMenuItem(appInfo.get_action_name(action));
|
let item = this._appendMenuItem(appInfo.get_action_name(action));
|
||||||
item.connect('activate', (emitter, event) => {
|
item.connect('activate', (emitter, event) => {
|
||||||
if (action == 'new-window' ||
|
if (action == 'new-window')
|
||||||
action == 'activate-discrete-gpu')
|
|
||||||
this._source.animateLaunch();
|
this._source.animateLaunch();
|
||||||
|
|
||||||
this._source.app.launch_action(action, event.get_time(), -1);
|
this._source.app.launch_action(action, event.get_time(), -1);
|
||||||
|
@ -55,6 +55,7 @@ const RENAMED_DESKTOP_IDS = {
|
|||||||
'org.gnome.taquin.desktop': 'org.gnome.Taquin.desktop',
|
'org.gnome.taquin.desktop': 'org.gnome.Taquin.desktop',
|
||||||
'org.gnome.Weather.Application.desktop': 'org.gnome.Weather.desktop',
|
'org.gnome.Weather.Application.desktop': 'org.gnome.Weather.desktop',
|
||||||
'polari.desktop': 'org.gnome.Polari.desktop',
|
'polari.desktop': 'org.gnome.Polari.desktop',
|
||||||
|
'shotwell.desktop': 'org.gnome.Shotwell.desktop',
|
||||||
'tali.desktop': 'org.gnome.Tali.desktop',
|
'tali.desktop': 'org.gnome.Tali.desktop',
|
||||||
'totem.desktop': 'org.gnome.Totem.desktop',
|
'totem.desktop': 'org.gnome.Totem.desktop',
|
||||||
'evince.desktop': 'org.gnome.Evince.desktop',
|
'evince.desktop': 'org.gnome.Evince.desktop',
|
||||||
|
14
js/ui/dnd.js
14
js/ui/dnd.js
@ -573,11 +573,15 @@ var _Draggable = class _Draggable {
|
|||||||
while (target) {
|
while (target) {
|
||||||
if (target._delegate && target._delegate.acceptDrop) {
|
if (target._delegate && target._delegate.acceptDrop) {
|
||||||
let [r_, targX, targY] = target.transform_stage_point(dropX, dropY);
|
let [r_, targX, targY] = target.transform_stage_point(dropX, dropY);
|
||||||
if (target._delegate.acceptDrop(this.actor._delegate,
|
let accepted = false;
|
||||||
this._dragActor,
|
try {
|
||||||
targX,
|
accepted = target._delegate.acceptDrop(this.actor._delegate,
|
||||||
targY,
|
this._dragActor, targX, targY, event.get_time());
|
||||||
event.get_time())) {
|
} catch (e) {
|
||||||
|
// On error, skip this target
|
||||||
|
logError(e, "Skipping drag target");
|
||||||
|
}
|
||||||
|
if (accepted) {
|
||||||
// If it accepted the drop without taking the actor,
|
// If it accepted the drop without taking the actor,
|
||||||
// handle it ourselves.
|
// handle it ourselves.
|
||||||
if (this._dragActor && this._dragActor.get_parent() == Main.uiGroup) {
|
if (this._dragActor && this._dragActor.get_parent() == Main.uiGroup) {
|
||||||
|
@ -105,6 +105,16 @@ function _easeActor(actor, params) {
|
|||||||
actor.set_easing_delay(params.delay);
|
actor.set_easing_delay(params.delay);
|
||||||
delete params.delay;
|
delete params.delay;
|
||||||
|
|
||||||
|
let repeatCount = 0;
|
||||||
|
if (params.repeatCount != undefined)
|
||||||
|
repeatCount = params.repeatCount;
|
||||||
|
delete params.repeatCount;
|
||||||
|
|
||||||
|
let autoReverse = false;
|
||||||
|
if (params.autoReverse != undefined)
|
||||||
|
autoReverse = params.autoReverse;
|
||||||
|
delete params.autoReverse;
|
||||||
|
|
||||||
if (params.mode != undefined)
|
if (params.mode != undefined)
|
||||||
actor.set_easing_mode(params.mode);
|
actor.set_easing_mode(params.mode);
|
||||||
delete params.mode;
|
delete params.mode;
|
||||||
@ -127,10 +137,12 @@ function _easeActor(actor, params) {
|
|||||||
else
|
else
|
||||||
Meta.disable_unredirect_for_display(global.display);
|
Meta.disable_unredirect_for_display(global.display);
|
||||||
|
|
||||||
if (transition)
|
if (transition) {
|
||||||
|
transition.set({ repeatCount, autoReverse });
|
||||||
transition.connect('stopped', (t, finished) => callback(finished));
|
transition.connect('stopped', (t, finished) => callback(finished));
|
||||||
else
|
} else {
|
||||||
callback(true);
|
callback(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function _easeActorProperty(actor, propName, target, params) {
|
function _easeActorProperty(actor, propName, target, params) {
|
||||||
@ -143,6 +155,16 @@ function _easeActorProperty(actor, propName, target, params) {
|
|||||||
params.duration = adjustAnimationTime(params.duration);
|
params.duration = adjustAnimationTime(params.duration);
|
||||||
let duration = Math.floor(params.duration || 0);
|
let duration = Math.floor(params.duration || 0);
|
||||||
|
|
||||||
|
let repeatCount = 0;
|
||||||
|
if (params.repeatCount != undefined)
|
||||||
|
repeatCount = params.repeatCount;
|
||||||
|
delete params.repeatCount;
|
||||||
|
|
||||||
|
let autoReverse = false;
|
||||||
|
if (params.autoReverse != undefined)
|
||||||
|
autoReverse = params.autoReverse;
|
||||||
|
delete params.autoReverse;
|
||||||
|
|
||||||
// Copy Clutter's behavior for implicit animations, see
|
// Copy Clutter's behavior for implicit animations, see
|
||||||
// should_skip_implicit_transition()
|
// should_skip_implicit_transition()
|
||||||
if (actor instanceof Clutter.Actor && !actor.mapped)
|
if (actor instanceof Clutter.Actor && !actor.mapped)
|
||||||
@ -168,7 +190,9 @@ function _easeActorProperty(actor, propName, target, params) {
|
|||||||
let transition = new Clutter.PropertyTransition(Object.assign({
|
let transition = new Clutter.PropertyTransition(Object.assign({
|
||||||
property_name: propName,
|
property_name: propName,
|
||||||
interval: new Clutter.Interval({ value_type: pspec.value_type }),
|
interval: new Clutter.Interval({ value_type: pspec.value_type }),
|
||||||
remove_on_complete: true
|
remove_on_complete: true,
|
||||||
|
repeat_count: repeatCount,
|
||||||
|
auto_reverse: autoReverse,
|
||||||
}, params));
|
}, params));
|
||||||
actor.add_transition(propName, transition);
|
actor.add_transition(propName, transition);
|
||||||
|
|
||||||
|
@ -477,16 +477,16 @@ class RedBorderEffect extends Clutter.Effect {
|
|||||||
color.init_from_4ub(0xff, 0, 0, 0xc4);
|
color.init_from_4ub(0xff, 0, 0, 0xc4);
|
||||||
Cogl.set_source_color(color);
|
Cogl.set_source_color(color);
|
||||||
|
|
||||||
let geom = actor.get_allocation_geometry();
|
let alloc = actor.get_allocation_box();
|
||||||
let width = 2;
|
let width = 2;
|
||||||
|
|
||||||
// clockwise order
|
// clockwise order
|
||||||
Cogl.rectangle(0, 0, geom.width, width);
|
Cogl.rectangle(0, 0, alloc.get_width(), width);
|
||||||
Cogl.rectangle(geom.width - width, width,
|
Cogl.rectangle(alloc.get_width() - width, width,
|
||||||
geom.width, geom.height);
|
alloc.get_width(), alloc.get_height());
|
||||||
Cogl.rectangle(0, geom.height,
|
Cogl.rectangle(0, alloc.get_height(),
|
||||||
geom.width - width, geom.height - width);
|
alloc.get_width() - width, alloc.get_height() - width);
|
||||||
Cogl.rectangle(0, geom.height - width,
|
Cogl.rectangle(0, alloc.get_height() - width,
|
||||||
width, width);
|
width, width);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
/* exported SearchResultsView, SearchResultInterface */
|
/* exported SearchResultsView */
|
||||||
|
|
||||||
const { Clutter, Gio, GLib, GObject, Meta, Shell, St } = imports.gi;
|
const { Clutter, Gio, GLib, GObject, Meta, Shell, St } = imports.gi;
|
||||||
|
|
||||||
@ -32,17 +32,8 @@ class MaxWidthBox extends St.BoxLayout {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
var SearchResultInterface = GObject.registerClass({
|
var SearchResult = GObject.registerClass(
|
||||||
Requires: [Clutter.Actor],
|
class SearchResult extends St.Button {
|
||||||
}, class SearchResultInterface extends GObject.Interface {
|
|
||||||
activate() {
|
|
||||||
throw new GObject.NotImplementedError('activate in %s'.format(this.constructor.name));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
var SearchResult = GObject.registerClass({
|
|
||||||
Implements: [SearchResultInterface]
|
|
||||||
}, class SearchResult extends St.Button {
|
|
||||||
_init(provider, metaInfo, resultsView) {
|
_init(provider, metaInfo, resultsView) {
|
||||||
this.provider = provider;
|
this.provider = provider;
|
||||||
this.metaInfo = metaInfo;
|
this.metaInfo = metaInfo;
|
||||||
@ -253,8 +244,6 @@ var SearchResultsBase = GObject.registerClass({
|
|||||||
metasNeeded.forEach((resultId, i) => {
|
metasNeeded.forEach((resultId, i) => {
|
||||||
let meta = metas[i];
|
let meta = metas[i];
|
||||||
let display = this._createResultDisplay(meta);
|
let display = this._createResultDisplay(meta);
|
||||||
if (!(display instanceof SearchResultInterface))
|
|
||||||
throw new Error(`${display} is not a valid search result`);
|
|
||||||
display.connect('key-focus-in', this._keyFocusIn.bind(this));
|
display.connect('key-focus-in', this._keyFocusIn.bind(this));
|
||||||
this._resultDisplays[resultId] = display;
|
this._resultDisplays[resultId] = display;
|
||||||
});
|
});
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
||||||
/* exported Workspace */
|
/* exported Workspace */
|
||||||
|
|
||||||
const { Atk, Clutter, GLib, GObject, Meta, Pango, Shell, St } = imports.gi;
|
const { Atk, Clutter, GLib, GObject,
|
||||||
|
Graphene, Meta, Pango, Shell, St } = imports.gi;
|
||||||
const Signals = imports.signals;
|
const Signals = imports.signals;
|
||||||
|
|
||||||
const DND = imports.ui.dnd;
|
const DND = imports.ui.dnd;
|
||||||
@ -158,6 +159,8 @@ var WindowClone = GObject.registerClass({
|
|||||||
this.x = this._boundingBox.x;
|
this.x = this._boundingBox.x;
|
||||||
this.y = this._boundingBox.y;
|
this.y = this._boundingBox.y;
|
||||||
|
|
||||||
|
this._computeWindowCenter();
|
||||||
|
|
||||||
let clickAction = new Clutter.ClickAction();
|
let clickAction = new Clutter.ClickAction();
|
||||||
clickAction.connect('clicked', this._onClicked.bind(this));
|
clickAction.connect('clicked', this._onClicked.bind(this));
|
||||||
clickAction.connect('long-press', this._onLongPress.bind(this));
|
clickAction.connect('long-press', this._onLongPress.bind(this));
|
||||||
@ -293,6 +296,18 @@ var WindowClone = GObject.registerClass({
|
|||||||
this.layout_manager.boundingBox = rect;
|
this.layout_manager.boundingBox = rect;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get windowCenter() {
|
||||||
|
return this._windowCenter;
|
||||||
|
}
|
||||||
|
|
||||||
|
_computeWindowCenter() {
|
||||||
|
let box = this.realWindow.get_allocation_box();
|
||||||
|
this._windowCenter = new Graphene.Point({
|
||||||
|
x: box.get_x() + box.get_width() / 2,
|
||||||
|
y: box.get_y() + box.get_height() / 2,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
// Find the actor just below us, respecting reparenting done by DND code
|
// Find the actor just below us, respecting reparenting done by DND code
|
||||||
getActualStackAbove() {
|
getActualStackAbove() {
|
||||||
if (this._stackAbove == null)
|
if (this._stackAbove == null)
|
||||||
@ -1017,11 +1032,7 @@ var UnalignedLayoutStrategy = class extends LayoutStrategy {
|
|||||||
_sortRow(row) {
|
_sortRow(row) {
|
||||||
// Sort windows horizontally to minimize travel distance.
|
// Sort windows horizontally to minimize travel distance.
|
||||||
// This affects in what order the windows end up in a row.
|
// This affects in what order the windows end up in a row.
|
||||||
row.windows.sort((a, b) => {
|
row.windows.sort((a, b) => a.windowCenter.x - b.windowCenter.x);
|
||||||
let aCenter = a.realWindow.x + a.realWindow.width / 2;
|
|
||||||
let bCenter = b.realWindow.x + b.realWindow.width / 2;
|
|
||||||
return aCenter - bCenter;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
computeLayout(windows, layout) {
|
computeLayout(windows, layout) {
|
||||||
@ -1040,11 +1051,7 @@ var UnalignedLayoutStrategy = class extends LayoutStrategy {
|
|||||||
// Sort windows vertically to minimize travel distance.
|
// Sort windows vertically to minimize travel distance.
|
||||||
// This affects what rows the windows get placed in.
|
// This affects what rows the windows get placed in.
|
||||||
let sortedWindows = windows.slice();
|
let sortedWindows = windows.slice();
|
||||||
sortedWindows.sort((a, b) => {
|
sortedWindows.sort((a, b) => a.windowCenter.y - b.windowCenter.y);
|
||||||
let aCenter = a.realWindow.y + a.realWindow.height / 2;
|
|
||||||
let bCenter = b.realWindow.y + b.realWindow.height / 2;
|
|
||||||
return aCenter - bCenter;
|
|
||||||
});
|
|
||||||
|
|
||||||
let windowIdx = 0;
|
let windowIdx = 0;
|
||||||
for (let i = 0; i < numRows; i++) {
|
for (let i = 0; i < numRows; i++) {
|
||||||
|
100
po/fur.po
100
po/fur.po
@ -7,15 +7,15 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: video-subtitles master\n"
|
"Project-Id-Version: video-subtitles master\n"
|
||||||
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/gnome-shell/issues\n"
|
||||||
"POT-Creation-Date: 2019-09-17 11:44+0000\n"
|
"POT-Creation-Date: 2019-10-12 20:48+0000\n"
|
||||||
"PO-Revision-Date: 2019-09-26 16:19+0200\n"
|
"PO-Revision-Date: 2019-10-17 15:53+0200\n"
|
||||||
"Last-Translator: Fabio Tomat <f.t.public@gmail.com>\n"
|
"Last-Translator: Fabio Tomat <f.t.public@gmail.com>\n"
|
||||||
"Language-Team: Friulian <fur@li.org>\n"
|
"Language-Team: Friulian <fur@li.org>\n"
|
||||||
"Language: fur\n"
|
"Language: fur\n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"X-Generator: Poedit 2.2.3\n"
|
"X-Generator: Poedit 2.2.4\n"
|
||||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
|
||||||
#: data/50-gnome-shell-system.xml:6
|
#: data/50-gnome-shell-system.xml:6
|
||||||
@ -467,7 +467,7 @@ msgid "Next"
|
|||||||
msgstr "Indenant"
|
msgstr "Indenant"
|
||||||
|
|
||||||
#: js/gdm/authPrompt.js:197 js/ui/shellMountOperation.js:396
|
#: js/gdm/authPrompt.js:197 js/ui/shellMountOperation.js:396
|
||||||
#: js/ui/unlockDialog.js:42
|
#: js/ui/unlockDialog.js:45
|
||||||
msgid "Unlock"
|
msgid "Unlock"
|
||||||
msgstr "Sbloche"
|
msgstr "Sbloche"
|
||||||
|
|
||||||
@ -497,8 +497,8 @@ msgstr "(p.e., utent o %s)"
|
|||||||
#. TTLS and PEAP are actually much more complicated, but this complication
|
#. TTLS and PEAP are actually much more complicated, but this complication
|
||||||
#. is not visible here since we only care about phase2 authentication
|
#. is not visible here since we only care about phase2 authentication
|
||||||
#. (and don't even care of which one)
|
#. (and don't even care of which one)
|
||||||
#: js/gdm/loginDialog.js:884 js/ui/components/networkAgent.js:247
|
#: js/gdm/loginDialog.js:884 js/ui/components/networkAgent.js:248
|
||||||
#: js/ui/components/networkAgent.js:267 js/ui/components/networkAgent.js:285
|
#: js/ui/components/networkAgent.js:268 js/ui/components/networkAgent.js:286
|
||||||
msgid "Username: "
|
msgid "Username: "
|
||||||
msgstr "Non utent: "
|
msgstr "Non utent: "
|
||||||
|
|
||||||
@ -760,32 +760,32 @@ msgstr "Dispès"
|
|||||||
msgid "All"
|
msgid "All"
|
||||||
msgstr "Dutis"
|
msgstr "Dutis"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:1749
|
#: js/ui/appDisplay.js:1745
|
||||||
msgid "Rename"
|
msgid "Rename"
|
||||||
msgstr "Cambie non"
|
msgstr "Cambie non"
|
||||||
|
|
||||||
#. Translators: This is the heading of a list of open windows
|
#. Translators: This is the heading of a list of open windows
|
||||||
#: js/ui/appDisplay.js:2397 js/ui/panel.js:76
|
#: js/ui/appDisplay.js:2418 js/ui/panel.js:76
|
||||||
msgid "Open Windows"
|
msgid "Open Windows"
|
||||||
msgstr "Barcons vierts"
|
msgstr "Barcons vierts"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:2416 js/ui/panel.js:83
|
#: js/ui/appDisplay.js:2437 js/ui/panel.js:83
|
||||||
msgid "New Window"
|
msgid "New Window"
|
||||||
msgstr "Gnûf barcon"
|
msgstr "Gnûf barcon"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:2428
|
#: js/ui/appDisplay.js:2449
|
||||||
msgid "Launch using Dedicated Graphics Card"
|
msgid "Launch using Dedicated Graphics Card"
|
||||||
msgstr "Invie doprant une schede grafiche dedicade"
|
msgstr "Invie doprant une schede grafiche dedicade"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:2457 js/ui/dash.js:239
|
#: js/ui/appDisplay.js:2478 js/ui/dash.js:239
|
||||||
msgid "Remove from Favorites"
|
msgid "Remove from Favorites"
|
||||||
msgstr "Gjave dai preferîts"
|
msgstr "Gjave dai preferîts"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:2463
|
#: js/ui/appDisplay.js:2484
|
||||||
msgid "Add to Favorites"
|
msgid "Add to Favorites"
|
||||||
msgstr "Zonte tai preferîts"
|
msgstr "Zonte tai preferîts"
|
||||||
|
|
||||||
#: js/ui/appDisplay.js:2473 js/ui/panel.js:94
|
#: js/ui/appDisplay.js:2494 js/ui/panel.js:94
|
||||||
msgid "Show Details"
|
msgid "Show Details"
|
||||||
msgstr "Mostre Detais"
|
msgstr "Mostre Detais"
|
||||||
|
|
||||||
@ -1017,34 +1017,34 @@ msgid "Connect"
|
|||||||
msgstr "Conet"
|
msgstr "Conet"
|
||||||
|
|
||||||
#. Cisco LEAP
|
#. Cisco LEAP
|
||||||
#: js/ui/components/networkAgent.js:216 js/ui/components/networkAgent.js:228
|
#: js/ui/components/networkAgent.js:217 js/ui/components/networkAgent.js:229
|
||||||
#: js/ui/components/networkAgent.js:250 js/ui/components/networkAgent.js:269
|
#: js/ui/components/networkAgent.js:251 js/ui/components/networkAgent.js:270
|
||||||
#: js/ui/components/networkAgent.js:289 js/ui/components/networkAgent.js:299
|
#: js/ui/components/networkAgent.js:290 js/ui/components/networkAgent.js:300
|
||||||
msgid "Password: "
|
msgid "Password: "
|
||||||
msgstr "Password: "
|
msgstr "Password: "
|
||||||
|
|
||||||
#. static WEP
|
#. static WEP
|
||||||
#: js/ui/components/networkAgent.js:221
|
#: js/ui/components/networkAgent.js:222
|
||||||
msgid "Key: "
|
msgid "Key: "
|
||||||
msgstr "Clâf: "
|
msgstr "Clâf: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:253 js/ui/components/networkAgent.js:275
|
#: js/ui/components/networkAgent.js:254 js/ui/components/networkAgent.js:276
|
||||||
msgid "Private key password: "
|
msgid "Private key password: "
|
||||||
msgstr "Password di clâf privade: "
|
msgstr "Password di clâf privade: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:273
|
#: js/ui/components/networkAgent.js:274
|
||||||
msgid "Identity: "
|
msgid "Identity: "
|
||||||
msgstr "Identitât: "
|
msgstr "Identitât: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:287
|
#: js/ui/components/networkAgent.js:288
|
||||||
msgid "Service: "
|
msgid "Service: "
|
||||||
msgstr "Servizi: "
|
msgstr "Servizi: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:316 js/ui/components/networkAgent.js:691
|
#: js/ui/components/networkAgent.js:317 js/ui/components/networkAgent.js:692
|
||||||
msgid "Authentication required by wireless network"
|
msgid "Authentication required by wireless network"
|
||||||
msgstr "La rêt cence fîl e domande autenticazion"
|
msgstr "La rêt cence fîl e domande autenticazion"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:317 js/ui/components/networkAgent.js:692
|
#: js/ui/components/networkAgent.js:318 js/ui/components/networkAgent.js:693
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid ""
|
msgid ""
|
||||||
"Passwords or encryption keys are required to access the wireless network "
|
"Passwords or encryption keys are required to access the wireless network "
|
||||||
@ -1053,41 +1053,41 @@ msgstr ""
|
|||||||
"Si scugne meti une password o une clâf di cifradure par jentrâ te rêt cence "
|
"Si scugne meti une password o une clâf di cifradure par jentrâ te rêt cence "
|
||||||
"fîl \"%s\"."
|
"fîl \"%s\"."
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:321 js/ui/components/networkAgent.js:696
|
#: js/ui/components/networkAgent.js:322 js/ui/components/networkAgent.js:697
|
||||||
msgid "Wired 802.1X authentication"
|
msgid "Wired 802.1X authentication"
|
||||||
msgstr "Autenticazion vie fîl 802.1X"
|
msgstr "Autenticazion vie fîl 802.1X"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:323
|
#: js/ui/components/networkAgent.js:324
|
||||||
msgid "Network name: "
|
msgid "Network name: "
|
||||||
msgstr "Non rêt: "
|
msgstr "Non rêt: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:328 js/ui/components/networkAgent.js:700
|
#: js/ui/components/networkAgent.js:329 js/ui/components/networkAgent.js:701
|
||||||
msgid "DSL authentication"
|
msgid "DSL authentication"
|
||||||
msgstr "Autenticazion DSL"
|
msgstr "Autenticazion DSL"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:335 js/ui/components/networkAgent.js:705
|
#: js/ui/components/networkAgent.js:336 js/ui/components/networkAgent.js:706
|
||||||
msgid "PIN code required"
|
msgid "PIN code required"
|
||||||
msgstr "Si pretint un codiç PIN"
|
msgstr "Si pretint un codiç PIN"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:336 js/ui/components/networkAgent.js:706
|
#: js/ui/components/networkAgent.js:337 js/ui/components/networkAgent.js:707
|
||||||
msgid "PIN code is needed for the mobile broadband device"
|
msgid "PIN code is needed for the mobile broadband device"
|
||||||
msgstr "Si scugne meti un codiç PIN pal dispositîf a bande largje mobil"
|
msgstr "Si scugne meti un codiç PIN pal dispositîf a bande largje mobil"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:337
|
#: js/ui/components/networkAgent.js:338
|
||||||
msgid "PIN: "
|
msgid "PIN: "
|
||||||
msgstr "PIN: "
|
msgstr "PIN: "
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:344 js/ui/components/networkAgent.js:712
|
#: js/ui/components/networkAgent.js:345 js/ui/components/networkAgent.js:713
|
||||||
msgid "Mobile broadband network password"
|
msgid "Mobile broadband network password"
|
||||||
msgstr "Passowrd rêt mobil a bande largje"
|
msgstr "Passowrd rêt mobil a bande largje"
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:345 js/ui/components/networkAgent.js:697
|
#: js/ui/components/networkAgent.js:346 js/ui/components/networkAgent.js:698
|
||||||
#: js/ui/components/networkAgent.js:701 js/ui/components/networkAgent.js:713
|
#: js/ui/components/networkAgent.js:702 js/ui/components/networkAgent.js:714
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "A password is required to connect to “%s”."
|
msgid "A password is required to connect to “%s”."
|
||||||
msgstr "A covente une password par tacâsi a '%s'."
|
msgstr "A covente une password par tacâsi a '%s'."
|
||||||
|
|
||||||
#: js/ui/components/networkAgent.js:680 js/ui/status/network.js:1675
|
#: js/ui/components/networkAgent.js:681 js/ui/status/network.js:1675
|
||||||
msgid "Network Manager"
|
msgid "Network Manager"
|
||||||
msgstr "Ministradôr di rêt"
|
msgstr "Ministradôr di rêt"
|
||||||
|
|
||||||
@ -1475,6 +1475,26 @@ msgstr "Viôt sorzint"
|
|||||||
msgid "Web Page"
|
msgid "Web Page"
|
||||||
msgstr "Pagjine Web"
|
msgstr "Pagjine Web"
|
||||||
|
|
||||||
|
#: js/ui/main.js:267
|
||||||
|
msgid "Logged in as a privileged user"
|
||||||
|
msgstr "Jentre come utent privilegjât"
|
||||||
|
|
||||||
|
#: js/ui/main.js:268
|
||||||
|
msgid ""
|
||||||
|
"Running a session as a privileged user should be avoided for security "
|
||||||
|
"reasons. If possible, you should log in as a normal user."
|
||||||
|
msgstr ""
|
||||||
|
"Si varès di evitâ di eseguî une session come utent privilegjât par resons di "
|
||||||
|
"sigurece. Se pussibil, tu varessis di jentrâ come utent normâl."
|
||||||
|
|
||||||
|
#: js/ui/main.js:274
|
||||||
|
msgid "Screen Lock disabled"
|
||||||
|
msgstr "Bloc dal schermi disabilitât"
|
||||||
|
|
||||||
|
#: js/ui/main.js:275
|
||||||
|
msgid "Screen Locking requires the GNOME display manager."
|
||||||
|
msgstr "Il bloc dal schermi al à bisugne dal gjestôr dai visôrs di GNOME."
|
||||||
|
|
||||||
#: js/ui/messageTray.js:1465
|
#: js/ui/messageTray.js:1465
|
||||||
msgid "System Information"
|
msgid "System Information"
|
||||||
msgstr "Informazion di sisteme"
|
msgstr "Informazion di sisteme"
|
||||||
@ -2219,11 +2239,11 @@ msgstr "Dome esterni"
|
|||||||
msgid "Built-in Only"
|
msgid "Built-in Only"
|
||||||
msgstr "Dome incorporât"
|
msgstr "Dome incorporât"
|
||||||
|
|
||||||
#: js/ui/unlockDialog.js:50
|
#: js/ui/unlockDialog.js:53
|
||||||
msgid "Log in as another user"
|
msgid "Log in as another user"
|
||||||
msgstr "Jentre come altri utent"
|
msgstr "Jentre come altri utent"
|
||||||
|
|
||||||
#: js/ui/unlockDialog.js:67
|
#: js/ui/unlockDialog.js:70
|
||||||
msgid "Unlock Window"
|
msgid "Unlock Window"
|
||||||
msgstr "Sbloche barcon"
|
msgstr "Sbloche barcon"
|
||||||
|
|
||||||
@ -2266,7 +2286,7 @@ msgstr[1] ""
|
|||||||
|
|
||||||
#. Translators: This represents the size of a window. The first number is
|
#. Translators: This represents the size of a window. The first number is
|
||||||
#. * the width of the window and the second is the height.
|
#. * the width of the window and the second is the height.
|
||||||
#: js/ui/windowManager.js:683
|
#: js/ui/windowManager.js:686
|
||||||
#, javascript-format
|
#, javascript-format
|
||||||
msgid "%d × %d"
|
msgid "%d × %d"
|
||||||
msgstr "%d × %d"
|
msgstr "%d × %d"
|
||||||
@ -2350,7 +2370,7 @@ msgstr ""
|
|||||||
|
|
||||||
#: src/extensions-tool/command-create.c:192 src/extensions-tool/main.c:169
|
#: src/extensions-tool/command-create.c:192 src/extensions-tool/main.c:169
|
||||||
msgid "Name"
|
msgid "Name"
|
||||||
msgstr "Non "
|
msgstr "Non"
|
||||||
|
|
||||||
#: src/extensions-tool/command-create.c:203
|
#: src/extensions-tool/command-create.c:203
|
||||||
#, c-format
|
#, c-format
|
||||||
@ -2604,7 +2624,7 @@ msgstr "Comants:"
|
|||||||
msgid "Print help"
|
msgid "Print help"
|
||||||
msgstr "Stampe jutori"
|
msgstr "Stampe jutori"
|
||||||
|
|
||||||
#: src/extensions-tool/main.c:248 src/main.c:468
|
#: src/extensions-tool/main.c:248 src/main.c:460
|
||||||
msgid "Print version"
|
msgid "Print version"
|
||||||
msgstr "Stampe version"
|
msgstr "Stampe version"
|
||||||
|
|
||||||
@ -2653,15 +2673,15 @@ msgstr "Instale complès di estensions"
|
|||||||
msgid "Use “%s” to get detailed help.\n"
|
msgid "Use “%s” to get detailed help.\n"
|
||||||
msgstr "Dopre “%s” par vê un jutori detaiât.\n"
|
msgstr "Dopre “%s” par vê un jutori detaiât.\n"
|
||||||
|
|
||||||
#: src/main.c:474
|
#: src/main.c:466
|
||||||
msgid "Mode used by GDM for login screen"
|
msgid "Mode used by GDM for login screen"
|
||||||
msgstr "Modalitât doprade da GDM pe videade di acès"
|
msgstr "Modalitât doprade da GDM pe videade di acès"
|
||||||
|
|
||||||
#: src/main.c:480
|
#: src/main.c:472
|
||||||
msgid "Use a specific mode, e.g. “gdm” for login screen"
|
msgid "Use a specific mode, e.g. “gdm” for login screen"
|
||||||
msgstr "Dopre une modalitât specifiche, par esempli “gdm” pe videade di acès"
|
msgstr "Dopre une modalitât specifiche, par esempli “gdm” pe videade di acès"
|
||||||
|
|
||||||
#: src/main.c:486
|
#: src/main.c:478
|
||||||
msgid "List possible modes"
|
msgid "List possible modes"
|
||||||
msgstr "Liste modalitâts pussibilis"
|
msgstr "Liste modalitâts pussibilis"
|
||||||
|
|
||||||
|
@ -509,7 +509,7 @@ shell_app_activate_full (ShellApp *app,
|
|||||||
case SHELL_APP_STATE_STOPPED:
|
case SHELL_APP_STATE_STOPPED:
|
||||||
{
|
{
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
if (!shell_app_launch (app, timestamp, workspace, FALSE, &error))
|
if (!shell_app_launch (app, timestamp, workspace, SHELL_APP_GPU_SELECTION_AUTO, &error))
|
||||||
{
|
{
|
||||||
char *msg;
|
char *msg;
|
||||||
msg = g_strdup_printf (_("Failed to launch “%s”"), shell_app_get_name (app));
|
msg = g_strdup_printf (_("Failed to launch “%s”"), shell_app_get_name (app));
|
||||||
@ -584,7 +584,7 @@ shell_app_open_new_window (ShellApp *app,
|
|||||||
* instance (Firefox). There are a few less-sensical cases such
|
* instance (Firefox). There are a few less-sensical cases such
|
||||||
* as say Pidgin.
|
* as say Pidgin.
|
||||||
*/
|
*/
|
||||||
shell_app_launch (app, 0, workspace, FALSE, NULL);
|
shell_app_launch (app, 0, workspace, SHELL_APP_GPU_SELECTION_AUTO, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -1255,19 +1255,37 @@ wait_pid (GDesktopAppInfo *appinfo,
|
|||||||
g_child_watch_add (pid, (GChildWatchFunc) g_spawn_close_pid, NULL);
|
g_child_watch_add (pid, (GChildWatchFunc) g_spawn_close_pid, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
get_with_discrete_gpu (ShellApp *app,
|
||||||
|
ShellAppGpuSelection discrete_gpu)
|
||||||
|
{
|
||||||
|
switch (discrete_gpu)
|
||||||
|
{
|
||||||
|
case SHELL_APP_GPU_SELECTION_INTEGRATED:
|
||||||
|
return FALSE;
|
||||||
|
case SHELL_APP_GPU_SELECTION_DISCRETE:
|
||||||
|
return TRUE;
|
||||||
|
case SHELL_APP_GPU_SELECTION_AUTO:
|
||||||
|
return g_desktop_app_info_get_boolean (app->info, "PreferRunOnDiscreteGPU") ||
|
||||||
|
g_desktop_app_info_get_boolean (app->info, "X-KDE-RunOnDiscreteGpu");
|
||||||
|
default:
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* shell_app_launch:
|
* shell_app_launch:
|
||||||
* @timestamp: Event timestamp, or 0 for current event timestamp
|
* @timestamp: Event timestamp, or 0 for current event timestamp
|
||||||
* @workspace: Start on this workspace, or -1 for default
|
* @workspace: Start on this workspace, or -1 for default
|
||||||
* @discrete_gpu: Whether to start on the discrete GPU
|
* @discrete_gpu: the preferred GPU to launch the application on.
|
||||||
* @error: A #GError
|
* @error: A #GError
|
||||||
*/
|
*/
|
||||||
gboolean
|
gboolean
|
||||||
shell_app_launch (ShellApp *app,
|
shell_app_launch (ShellApp *app,
|
||||||
guint timestamp,
|
guint timestamp,
|
||||||
int workspace,
|
int workspace,
|
||||||
gboolean discrete_gpu,
|
ShellAppGpuSelection discrete_gpu,
|
||||||
GError **error)
|
GError **error)
|
||||||
{
|
{
|
||||||
ShellGlobal *global;
|
ShellGlobal *global;
|
||||||
GAppLaunchContext *context;
|
GAppLaunchContext *context;
|
||||||
@ -1289,8 +1307,13 @@ shell_app_launch (ShellApp *app,
|
|||||||
|
|
||||||
global = shell_global_get ();
|
global = shell_global_get ();
|
||||||
context = shell_global_create_app_launch_context (global, timestamp, workspace);
|
context = shell_global_create_app_launch_context (global, timestamp, workspace);
|
||||||
if (discrete_gpu)
|
/* FIXME: this should probably check whether we're on a dual-GPU system */
|
||||||
g_app_launch_context_setenv (context, "DRI_PRIME", "1");
|
if (get_with_discrete_gpu (app, discrete_gpu))
|
||||||
|
{
|
||||||
|
g_app_launch_context_setenv (context, "DRI_PRIME", "1");
|
||||||
|
g_app_launch_context_setenv (context, "__NV_PRIME_RENDER_OFFLOAD", "1");
|
||||||
|
g_app_launch_context_setenv (context, "__GLX_VENDOR_LIBRARY_NAME", "nvidia");
|
||||||
|
}
|
||||||
|
|
||||||
/* Set LEAVE_DESCRIPTORS_OPEN in order to use an optimized gspawn
|
/* Set LEAVE_DESCRIPTORS_OPEN in order to use an optimized gspawn
|
||||||
* codepath. The shell's open file descriptors should be marked CLOEXEC
|
* codepath. The shell's open file descriptors should be marked CLOEXEC
|
||||||
|
@ -18,6 +18,12 @@ typedef enum {
|
|||||||
SHELL_APP_STATE_RUNNING
|
SHELL_APP_STATE_RUNNING
|
||||||
} ShellAppState;
|
} ShellAppState;
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
SHELL_APP_GPU_SELECTION_AUTO = -1,
|
||||||
|
SHELL_APP_GPU_SELECTION_INTEGRATED = 0,
|
||||||
|
SHELL_APP_GPU_SELECTION_DISCRETE = 1
|
||||||
|
} ShellAppGpuSelection;
|
||||||
|
|
||||||
const char *shell_app_get_id (ShellApp *app);
|
const char *shell_app_get_id (ShellApp *app);
|
||||||
|
|
||||||
GDesktopAppInfo *shell_app_get_app_info (ShellApp *app);
|
GDesktopAppInfo *shell_app_get_app_info (ShellApp *app);
|
||||||
@ -51,11 +57,11 @@ GSList *shell_app_get_pids (ShellApp *app);
|
|||||||
|
|
||||||
gboolean shell_app_is_on_workspace (ShellApp *app, MetaWorkspace *workspace);
|
gboolean shell_app_is_on_workspace (ShellApp *app, MetaWorkspace *workspace);
|
||||||
|
|
||||||
gboolean shell_app_launch (ShellApp *app,
|
gboolean shell_app_launch (ShellApp *app,
|
||||||
guint timestamp,
|
guint timestamp,
|
||||||
int workspace,
|
int workspace,
|
||||||
gboolean discrete_gpu,
|
ShellAppGpuSelection discrete_gpu,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
void shell_app_launch_action (ShellApp *app,
|
void shell_app_launch_action (ShellApp *app,
|
||||||
const char *action_name,
|
const char *action_name,
|
||||||
|
@ -489,7 +489,7 @@ st_box_layout_pick (ClutterActor *actor)
|
|||||||
for (child = clutter_actor_get_first_child (actor);
|
for (child = clutter_actor_get_first_child (actor);
|
||||||
child != NULL;
|
child != NULL;
|
||||||
child = clutter_actor_get_next_sibling (child))
|
child = clutter_actor_get_next_sibling (child))
|
||||||
clutter_actor_paint (child);
|
clutter_actor_pick (child);
|
||||||
|
|
||||||
if (priv->hadjustment || priv->vadjustment)
|
if (priv->hadjustment || priv->vadjustment)
|
||||||
cogl_framebuffer_pop_clip (fb);
|
cogl_framebuffer_pop_clip (fb);
|
||||||
|
@ -302,11 +302,11 @@ st_scroll_view_pick (ClutterActor *actor)
|
|||||||
CLUTTER_ACTOR_CLASS (st_scroll_view_parent_class)->pick (actor);
|
CLUTTER_ACTOR_CLASS (st_scroll_view_parent_class)->pick (actor);
|
||||||
|
|
||||||
if (priv->child)
|
if (priv->child)
|
||||||
clutter_actor_paint (priv->child);
|
clutter_actor_pick (priv->child);
|
||||||
if (priv->hscrollbar_visible)
|
if (priv->hscrollbar_visible)
|
||||||
clutter_actor_paint (priv->hscroll);
|
clutter_actor_pick (priv->hscroll);
|
||||||
if (priv->vscrollbar_visible)
|
if (priv->vscrollbar_visible)
|
||||||
clutter_actor_paint (priv->vscroll);
|
clutter_actor_pick (priv->vscroll);
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
@ -36,16 +36,16 @@ function test() {
|
|||||||
obin.connect_after('paint', actor => {
|
obin.connect_after('paint', actor => {
|
||||||
Cogl.set_source_color4f(0, 1, 0, 1);
|
Cogl.set_source_color4f(0, 1, 0, 1);
|
||||||
|
|
||||||
let geom = actor.get_allocation_geometry();
|
let alloc = actor.get_allocation_box();
|
||||||
let width = 3;
|
let width = 3;
|
||||||
|
|
||||||
// clockwise order
|
// clockwise order
|
||||||
Cogl.rectangle(0, 0, geom.width, width);
|
Cogl.rectangle(0, 0, alloc.get_width(), width);
|
||||||
Cogl.rectangle(geom.width - width, width,
|
Cogl.rectangle(alloc.get_width() - width, width,
|
||||||
geom.width, geom.height);
|
alloc.get_width(), alloc.get_height());
|
||||||
Cogl.rectangle(0, geom.height,
|
Cogl.rectangle(0, alloc.get_height(),
|
||||||
geom.width - width, geom.height - width);
|
alloc.get_width() - width, alloc.get_height() - width);
|
||||||
Cogl.rectangle(0, geom.height - width,
|
Cogl.rectangle(0, alloc.get_height() - width,
|
||||||
width, width);
|
width, width);
|
||||||
});
|
});
|
||||||
tbox.add(obin);
|
tbox.add(obin);
|
||||||
|
Reference in New Issue
Block a user