overviewControls: account for the search entry in each control
Account for the search entry space at the bottom (the former message tray clone) individually in each side control, instead of packing another actor in the overview. This allows us to extend the central view all the way to the bottom, while still keeping controls centered vertically. https://bugzilla.gnome.org/show_bug.cgi?id=693987
This commit is contained in:
parent
060c049056
commit
66cdbc5cad
@ -718,6 +718,7 @@ StScrollBar StButton#vhandle:active {
|
||||
-vertical-spacing: 32px;
|
||||
padding-left: 32px;
|
||||
padding-right: 32px;
|
||||
padding-bottom: 32px;
|
||||
}
|
||||
|
||||
.window-picker.external-monitor {
|
||||
@ -849,13 +850,13 @@ StScrollBar StButton#vhandle:active {
|
||||
}
|
||||
|
||||
.all-app {
|
||||
padding: 16px 16px 16px 48px;
|
||||
padding: 0px 16px 32px 32px;
|
||||
spacing: 20px;
|
||||
}
|
||||
|
||||
.all-app:rtl {
|
||||
padding-left: 16px;
|
||||
padding-right: 48px;
|
||||
padding-right: 32px;
|
||||
}
|
||||
|
||||
.app-filter {
|
||||
|
@ -230,7 +230,8 @@ const Overview = new Lang.Class({
|
||||
this._thumbnailsBox = new WorkspaceThumbnail.ThumbnailsBox();
|
||||
this._controls = new OverviewControls.ControlsManager(this._dash,
|
||||
this._thumbnailsBox,
|
||||
this._viewSelector);
|
||||
this._viewSelector,
|
||||
this._searchEntryBin);
|
||||
|
||||
// Pack all the actors into the group
|
||||
this._group.add_actor(this._controls.dashActor);
|
||||
@ -242,14 +243,6 @@ const Overview = new Lang.Class({
|
||||
this._overview.add(this._group, { y_fill: true,
|
||||
expand: true });
|
||||
|
||||
// Then account for message tray
|
||||
this._messageTrayGhost = new St.Bin({ style_class: 'message-tray-summary',
|
||||
reactive: false,
|
||||
opacity: 0,
|
||||
x_fill: true,
|
||||
y_fill: true });
|
||||
this._overview.add_actor(this._messageTrayGhost);
|
||||
|
||||
// TODO - recalculate everything when desktop size changes
|
||||
this.dashIconSize = this._dash.iconSize;
|
||||
this._dash.connect('icon-size-changed',
|
||||
|
@ -294,15 +294,37 @@ const DashSlider = new Lang.Class({
|
||||
}
|
||||
});
|
||||
|
||||
const SlidingControlContainer = new Lang.Class({
|
||||
Name: 'SlidingControlContainer',
|
||||
Extends: St.Widget,
|
||||
|
||||
_init: function(child, entryBin) {
|
||||
this._layout = new Clutter.BoxLayout({ vertical: true });
|
||||
this.parent({ layout_manager: this._layout });
|
||||
|
||||
child.x_expand = true;
|
||||
this.add_actor(child);
|
||||
|
||||
let entryClone = new St.Widget();
|
||||
entryClone.height = entryBin.height;
|
||||
this.add_actor(entryClone);
|
||||
|
||||
entryBin.connect('notify::height', Lang.bind(this,
|
||||
function() {
|
||||
entryClone.height = entryBin.height;
|
||||
}));
|
||||
}
|
||||
});
|
||||
|
||||
const ControlsManager = new Lang.Class({
|
||||
Name: 'ControlsManager',
|
||||
|
||||
_init: function(dash, thumbnails, viewSelector) {
|
||||
_init: function(dash, thumbnails, viewSelector, entryBin) {
|
||||
this._dashSlider = new DashSlider(dash);
|
||||
this.dashActor = this._dashSlider.actor;
|
||||
this.dashActor = new SlidingControlContainer(this._dashSlider.actor, entryBin);
|
||||
|
||||
this._thumbnailsSlider = new ThumbnailsSlider(thumbnails);
|
||||
this.thumbnailsActor = this._thumbnailsSlider.actor;
|
||||
this.thumbnailsActor = new SlidingControlContainer(this._thumbnailsSlider.actor, entryBin);
|
||||
|
||||
this._viewSelector = viewSelector;
|
||||
this._viewSelector.connect('page-changed', Lang.bind(this, this._setVisibility));
|
||||
|
Loading…
Reference in New Issue
Block a user