mirror of
https://github.com/morgan9e/dash-to-panel
synced 2026-04-14 00:04:17 +09:00
Merge branch 'master' into vertical-panel
This commit is contained in:
@@ -176,7 +176,7 @@ Ideas for recursing child actors and assigning inline styles are based on code f
|
||||
@imrvelj, @Teslator, @bil-elmoussaoui, @brandon-schumann, @sw9, @rockon999 , @lexruee, @3v1n0, @freeroot, @moqmar, @ArtyomZorin, @lkc0987, @saibotk, @vanillajonathan, @Zkdc
|
||||
|
||||
#### Translations:
|
||||
@frnogueira (pt_BR), @zeten30 (cs), @franglais125 (es), @LaurentTreguier / @SolarLiner (fr), @elsieholmes (uk), @hosiet (zh\_CN), @jonnius (de), @urbalazs / @pappfer (hu), @crayxt (kk), @pkomur / MartinPL (pl), @AlexGluck / @GoodNike (ru), @sicklylife-jp (jp), @oltulu / @TeknoMobil / @daenney (tr), @sbadux (it), @OriginCode (zh\_TW)
|
||||
@frnogueira (pt_BR), @zeten30 (cs), @franglais125 (es), @LaurentTreguier / @SolarLiner (fr), @elsieholmes (uk), @hosiet (zh\_CN), @jonnius (de), @urbalazs / @pappfer (hu), @crayxt (kk), @pkomur / @MartinPL / @alex4401 (pl), @AlexGluck / @GoodNike (ru), @sicklylife-jp (jp), @oltulu / @TeknoMobil / @daenney (tr), @sbadux (it), @OriginCode / @pan93412 (zh\_TW)
|
||||
|
||||
|
||||
##
|
||||
|
||||
509
Settings.ui
509
Settings.ui
@@ -2264,35 +2264,6 @@
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="leave_timeout_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Time (ms) before hiding (100 is default)</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkSpinButton" id="leave_timeout_spinbutton">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="width_chars">4</property>
|
||||
<property name="text">25</property>
|
||||
<property name="adjustment">leave_timeout_adjustment</property>
|
||||
<property name="numeric">True</property>
|
||||
<property name="value">25</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="animation_time_label">
|
||||
<property name="visible">True</property>
|
||||
@@ -2321,6 +2292,74 @@
|
||||
<property name="top_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="preview_hide_box">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="leave_timeout_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Time (ms) before hiding (100 is default)</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="preview_immediate_click_button">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="margin_left">12</property>
|
||||
<property name="margin_top">4</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="preview_immediate_click_label">
|
||||
<property name="name">4</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="halign">start</property>
|
||||
<property name="margin_left">4</property>
|
||||
<property name="label" translatable="yes">Immediate on application icon click</property>
|
||||
<property name="use_markup">True</property>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkSpinButton" id="leave_timeout_spinbutton">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="width_chars">4</property>
|
||||
<property name="text">25</property>
|
||||
<property name="adjustment">leave_timeout_adjustment</property>
|
||||
<property name="numeric">True</property>
|
||||
<property name="value">25</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
@@ -3134,6 +3173,182 @@
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="scroll_icon_options_delay_adjustment">
|
||||
<property name="upper">2000</property>
|
||||
<property name="step_increment">10</property>
|
||||
<property name="page_increment">50</property>
|
||||
</object>
|
||||
<object class="GtkBox" id="scroll_icon_options_box">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkListBox" id="scroll_icon_options_listbox">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="selection_mode">none</property>
|
||||
<child>
|
||||
<object class="GtkListBoxRow" id="listboxrow_scroll_icon_options_delay">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="grid_scroll_icon_options_delay">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="margin_left">12</property>
|
||||
<property name="margin_right">12</property>
|
||||
<property name="margin_top">12</property>
|
||||
<property name="margin_bottom">12</property>
|
||||
<property name="column_spacing">32</property>
|
||||
<child>
|
||||
<object class="GtkSpinButton" id="scroll_icon_options_delay_spinbutton">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="width_chars">4</property>
|
||||
<property name="text">50</property>
|
||||
<property name="adjustment">scroll_icon_options_delay_adjustment</property>
|
||||
<property name="numeric">True</property>
|
||||
<property name="value">50</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="height">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_icon_options_delay_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Delay between mouse scroll events (ms)</property>
|
||||
<property name="use_markup">True</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_icon_options_delay_description">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Use this value to limit the number of captured mouse scroll events.</property>
|
||||
<property name="wrap">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<style>
|
||||
<class name="dim-label"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="scroll_panel_options_delay_adjustment">
|
||||
<property name="upper">2000</property>
|
||||
<property name="step_increment">10</property>
|
||||
<property name="page_increment">50</property>
|
||||
</object>
|
||||
<object class="GtkBox" id="scroll_panel_options_box">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkListBox" id="scroll_panel_options_listbox">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="selection_mode">none</property>
|
||||
<child>
|
||||
<object class="GtkListBoxRow" id="listboxrow_scroll_panel_options_delay">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="grid_scroll_panel_options_delay">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="margin_left">12</property>
|
||||
<property name="margin_right">12</property>
|
||||
<property name="margin_top">12</property>
|
||||
<property name="margin_bottom">12</property>
|
||||
<property name="column_spacing">32</property>
|
||||
<child>
|
||||
<object class="GtkSpinButton" id="scroll_panel_options_delay_spinbutton">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="width_chars">4</property>
|
||||
<property name="text">50</property>
|
||||
<property name="adjustment">scroll_panel_options_delay_adjustment</property>
|
||||
<property name="numeric">True</property>
|
||||
<property name="value">50</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="height">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_panel_options_delay_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Delay between mouse scroll events (ms)</property>
|
||||
<property name="use_markup">True</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_panel_options_delay_description">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Use this value to limit the number of captured mouse scroll events.</property>
|
||||
<property name="wrap">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<style>
|
||||
<class name="dim-label"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="shortcut_time_adjustment">
|
||||
<property name="upper">10000</property>
|
||||
<property name="step_increment">250</property>
|
||||
@@ -6133,6 +6348,32 @@
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child type="tab">
|
||||
<object class="GtkLabel" id="behaviour_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">Behavior</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">2</property>
|
||||
<property name="tab_fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="action">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="margin_left">24</property>
|
||||
<property name="margin_right">24</property>
|
||||
<property name="margin_top">24</property>
|
||||
<property name="margin_bottom">24</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<property name="spacing">24</property>
|
||||
<child>
|
||||
<object class="GtkFrame" id="built_in_theme_frame3">
|
||||
<property name="can_focus">False</property>
|
||||
@@ -6251,6 +6492,198 @@
|
||||
<placeholder/>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkFrame" id="scroll_action_frame">
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label_xalign">0</property>
|
||||
<property name="shadow_type">in</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="scroll_action_grid">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="margin_left">12</property>
|
||||
<property name="margin_right">12</property>
|
||||
<property name="margin_top">12</property>
|
||||
<property name="margin_bottom">12</property>
|
||||
<property name="row_spacing">16</property>
|
||||
<property name="column_spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkBox" id="scroll_panel_description_box">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_panel_description_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Scroll panel action</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_panel_description">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Behavior when mouse scrolling over the panel.</property>
|
||||
<property name="wrap">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<style>
|
||||
<class name="dim-label"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="scroll_icon_description_box">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_icon_description_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Scroll icon action</property>
|
||||
<property name="xalign">0</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="scroll_icon_description">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="label" translatable="yes">Behavior when mouse scrolling over an application icon.</property>
|
||||
<property name="wrap">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<style>
|
||||
<class name="dim-label"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkButton" id="scroll_panel_options_button">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<child>
|
||||
<object class="GtkImage" id="scroll_panel_options_button_image">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="icon_name">emblem-system-symbolic</property>
|
||||
</object>
|
||||
</child>
|
||||
<style>
|
||||
<class name="circular"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBoxText" id="scroll_panel_combo">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="hexpand">True</property>
|
||||
<items>
|
||||
<item id="NOTHING" translatable="yes">Do nothing</item>
|
||||
<item id="SWITCH_WORKSPACE" translatable="yes">Switch workspace</item>
|
||||
<item id="CYCLE_WINDOWS" translatable="yes">Cycle windows</item>
|
||||
</items>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBoxText" id="scroll_icon_combo">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="hexpand">True</property>
|
||||
<items>
|
||||
<item id="NOTHING" translatable="yes">Do nothing</item>
|
||||
<item id="CYCLE_WINDOWS" translatable="yes">Cycle windows</item>
|
||||
</items>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkButton" id="scroll_icon_options_button">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<child>
|
||||
<object class="GtkImage" id="scroll_icon_options_button_image">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="icon_name">emblem-system-symbolic</property>
|
||||
</object>
|
||||
</child>
|
||||
<style>
|
||||
<class name="circular"/>
|
||||
</style>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
<child type="label_item">
|
||||
<placeholder/>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
@@ -6375,22 +6808,22 @@
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">2</property>
|
||||
<property name="position">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">2</property>
|
||||
<property name="position">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child type="tab">
|
||||
<object class="GtkLabel" id="behaviour_label">
|
||||
<object class="GtkLabel" id="action_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">Behavior</property>
|
||||
<property name="label" translatable="yes">Action</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">2</property>
|
||||
<property name="position">3</property>
|
||||
<property name="tab_fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
@@ -6913,7 +7346,7 @@
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">3</property>
|
||||
<property name="position">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child type="tab">
|
||||
@@ -6924,7 +7357,7 @@
|
||||
<property name="label" translatable="yes">Fine-Tune</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">3</property>
|
||||
<property name="position">4</property>
|
||||
<property name="tab_fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
@@ -7135,7 +7568,7 @@ See the <a href="https://www.gnu.org/licenses/old-licenses/gpl-2.0.html">G
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">4</property>
|
||||
<property name="position">5</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child type="tab">
|
||||
@@ -7145,7 +7578,7 @@ See the <a href="https://www.gnu.org/licenses/old-licenses/gpl-2.0.html">G
|
||||
<property name="label" translatable="yes">About</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">4</property>
|
||||
<property name="position">5</property>
|
||||
<property name="tab_fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
95
appIcons.js
95
appIcons.js
@@ -50,10 +50,6 @@ const Utils = Me.imports.utils;
|
||||
const Taskbar = Me.imports.taskbar;
|
||||
const _ = imports.gettext.domain(Utils.TRANSLATION_DOMAIN).gettext;
|
||||
|
||||
let DASH_ANIMATION_TIME = Dash.DASH_ANIMATION_TIME;
|
||||
let DASH_ITEM_LABEL_SHOW_TIME = Dash.DASH_ITEM_LABEL_SHOW_TIME;
|
||||
let DASH_ITEM_LABEL_HIDE_TIME = Dash.DASH_ITEM_LABEL_HIDE_TIME;
|
||||
let DASH_ITEM_HOVER_TIMEOUT = Dash.DASH_ITEM_HOVER_TIMEOUT;
|
||||
let LABEL_GAP = 5;
|
||||
let MAX_INDICATORS = 4;
|
||||
|
||||
@@ -95,7 +91,7 @@ let tracker = Shell.WindowTracker.get_default();
|
||||
|
||||
var taskbarAppIcon = Utils.defineClass({
|
||||
Name: 'DashToPanel.TaskbarAppIcon',
|
||||
Extends: AppDisplay.AppIcon,
|
||||
Extends: (Dash.DashIcon || AppDisplay.AppIcon),
|
||||
ParentConstrParams: [[1, 'app'], [3]],
|
||||
|
||||
_init: function(settings, appInfo, panelWrapper, iconParams, previewMenu) {
|
||||
@@ -197,6 +193,8 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
Lang.bind(this, this._updateWindowTitle));
|
||||
}
|
||||
|
||||
this._scrollEventId = this.actor.connect('scroll-event', this._onMouseScroll.bind(this));
|
||||
|
||||
this._overviewWindowDragEndId = Main.overview.connect('window-drag-end',
|
||||
Lang.bind(this, this._onOverviewWindowDragEnd));
|
||||
|
||||
@@ -296,6 +294,15 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
this.actor.disconnect(this._hoverChangeId);
|
||||
}
|
||||
|
||||
if (this._scrollEventId) {
|
||||
this.actor.disconnect(this._scrollEventId);
|
||||
}
|
||||
|
||||
if (this._scrollIconDelayTimeoutId) {
|
||||
Mainloop.source_remove(this._scrollIconDelayTimeoutId);
|
||||
this._scrollIconDelayTimeoutId = 0;
|
||||
}
|
||||
|
||||
for (let i = 0; i < this._dtpSettingsSignalIds.length; ++i) {
|
||||
this._dtpSettings.disconnect(this._dtpSettingsSignalIds[i]);
|
||||
}
|
||||
@@ -334,6 +341,26 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
});
|
||||
},
|
||||
|
||||
_onMouseScroll: function(actor, event) {
|
||||
if (this._dtpSettings.get_string('scroll-icon-action') === 'NOTHING' ||
|
||||
(!this.window && !this._nWindows)) {
|
||||
return;
|
||||
}
|
||||
|
||||
let direction = Utils.getMouseScrollDirection(event);
|
||||
|
||||
if (direction && !this._scrollIconDelayTimeoutId) {
|
||||
this._scrollIconDelayTimeoutId = Mainloop.timeout_add(this._dtpSettings.get_int('scroll-icon-delay'), () => {
|
||||
this._scrollIconDelayTimeoutId = 0;
|
||||
});
|
||||
|
||||
let windows = this.getAppIconInterestingWindows();
|
||||
|
||||
windows.sort(Taskbar.sortWindowsCompareFunction);
|
||||
Utils.activateSiblingWindow(windows, direction, this.window);
|
||||
}
|
||||
},
|
||||
|
||||
_showDots: function() {
|
||||
// Just update style if dots already exist
|
||||
if (this._focusedDots && this._unfocusedDots) {
|
||||
@@ -543,7 +570,14 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
},
|
||||
|
||||
_onSwitchWorkspace: function(windowTracker) {
|
||||
this._displayProperIndicator();
|
||||
if (this._isGroupApps) {
|
||||
Mainloop.timeout_add(0, Lang.bind(this, function () {
|
||||
this._displayProperIndicator();
|
||||
return GLib.SOURCE_REMOVE;
|
||||
}));
|
||||
} else {
|
||||
this._displayProperIndicator();
|
||||
}
|
||||
},
|
||||
|
||||
_displayProperIndicator: function (force) {
|
||||
@@ -623,7 +657,7 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
dots._tweeningToWidth = newWidth;
|
||||
Tweener.addTween(dots,
|
||||
{ width: newWidth,
|
||||
time: DASH_ANIMATION_TIME,
|
||||
time: Taskbar.DASH_ANIMATION_TIME,
|
||||
transition: 'easeInOutCubic',
|
||||
onStart: Lang.bind(this, function() {
|
||||
if(newOtherOpacity == 0)
|
||||
@@ -702,8 +736,8 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
}
|
||||
|
||||
let appCount = this.getAppIconInterestingWindows().length;
|
||||
if (!(buttonAction == "TOGGLE-SHOWPREVIEW") || (appCount <= 1))
|
||||
this._previewMenu.close(true);
|
||||
let previewedAppIcon = this._previewMenu.getCurrentAppIcon();
|
||||
this._previewMenu.close(this._dtpSettings.get_boolean('window-preview-hide-immediate-click'));
|
||||
|
||||
// We check if the app is running, and that the # of windows is > 0 in
|
||||
// case we use workspace isolation,
|
||||
@@ -756,10 +790,7 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
if (appHasFocus || button == 2 || modifiers & Clutter.ModifierType.SHIFT_MASK) {
|
||||
// minimize all windows on double click and always in the case of primary click without
|
||||
// additional modifiers
|
||||
let click_count = 0;
|
||||
if (Clutter.EventType.CLUTTER_BUTTON_PRESS)
|
||||
click_count = event.get_click_count();
|
||||
let all_windows = (button == 1 && ! modifiers) || click_count > 1;
|
||||
let all_windows = (button == 1 && ! modifiers) || event.get_click_count() > 1;
|
||||
minimizeWindow(this.app, all_windows, this._dtpSettings, monitor);
|
||||
}
|
||||
else
|
||||
@@ -799,14 +830,15 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
else
|
||||
activateFirstWindow(this.app, this._dtpSettings, monitor);
|
||||
} else {
|
||||
// minimize all windows if double clicked
|
||||
if (Clutter.EventType.CLUTTER_BUTTON_PRESS) {
|
||||
let click_count = event.get_click_count();
|
||||
if(click_count > 1) {
|
||||
minimizeWindow(this.app, true, this._dtpSettings, monitor);
|
||||
}
|
||||
if (event.get_click_count() > 1) {
|
||||
// minimize all windows if double clicked
|
||||
minimizeWindow(this.app, true, this._dtpSettings, monitor);
|
||||
} else if (previewedAppIcon != this) {
|
||||
this._previewMenu.open(this);
|
||||
}
|
||||
}
|
||||
|
||||
this.emit('sync-tooltip');
|
||||
}
|
||||
}
|
||||
else
|
||||
this.app.activate();
|
||||
@@ -1096,6 +1128,7 @@ var taskbarAppIcon = Utils.defineClass({
|
||||
}
|
||||
|
||||
});
|
||||
taskbarAppIcon.prototype.scaleAndFade = taskbarAppIcon.prototype.undoScaleAndFade = () => {};
|
||||
|
||||
function minimizeWindow(app, param, settings, monitor){
|
||||
// Param true make all app windows minimize
|
||||
@@ -1429,11 +1462,20 @@ function ItemShowLabel() {
|
||||
x -= x + labelWidth -( monitor.x + monitor.width) + gap;
|
||||
|
||||
this.label.set_position(x, y);
|
||||
Tweener.addTween(this.label,
|
||||
{ opacity: 255,
|
||||
time: DASH_ITEM_LABEL_SHOW_TIME,
|
||||
transition: 'easeOutQuad',
|
||||
});
|
||||
|
||||
if (Dash.DASH_ITEM_LABEL_SHOW_TIME < 1) {
|
||||
Tweener.addTween(this.label, {
|
||||
opacity: 255,
|
||||
time: Dash.DASH_ITEM_LABEL_SHOW_TIME,
|
||||
transition: 'easeOutQuad',
|
||||
});
|
||||
} else {
|
||||
this.label.ease({
|
||||
opacity: 255,
|
||||
duration: Dash.DASH_ITEM_LABEL_SHOW_TIME,
|
||||
mode: Clutter.AnimationMode.EASE_OUT_QUAD
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -1462,6 +1504,7 @@ var ShowAppsIconWrapper = Utils.defineClass({
|
||||
(actor): duplicate reference to easily reuse appIcon methods */
|
||||
this.actor = this.realShowAppsIcon.toggleButton;
|
||||
this.realShowAppsIcon.actor.y_align = Clutter.ActorAlign.START;
|
||||
this.realShowAppsIcon.show(false);
|
||||
|
||||
// Re-use appIcon methods
|
||||
this._removeMenuTimeout = AppDisplay.AppIcon.prototype._removeMenuTimeout;
|
||||
@@ -1487,7 +1530,7 @@ var ShowAppsIconWrapper = Utils.defineClass({
|
||||
this._menuManager = new PopupMenu.PopupMenuManager(this.actor);
|
||||
this._menuTimeoutId = 0;
|
||||
|
||||
this.realShowAppsIcon.showLabel = ItemShowLabel;
|
||||
Taskbar.extendDashItemContainer(this.realShowAppsIcon);
|
||||
|
||||
let customIconPath = this._dtpSettings.get_string('show-apps-icon-file');
|
||||
|
||||
|
||||
28
extension.js
28
extension.js
@@ -18,11 +18,6 @@
|
||||
*/
|
||||
|
||||
|
||||
const Me = imports.misc.extensionUtils.getCurrentExtension();
|
||||
const Convenience = Me.imports.convenience;
|
||||
const PanelManager = Me.imports.panelManager;
|
||||
const Utils = Me.imports.utils;
|
||||
|
||||
const Main = imports.ui.main;
|
||||
const Meta = imports.gi.Meta;
|
||||
const Gio = imports.gi.Gio;
|
||||
@@ -32,10 +27,14 @@ const Shell = imports.gi.Shell;
|
||||
const St = imports.gi.St;
|
||||
const WindowManager = imports.ui.windowManager;
|
||||
const ExtensionUtils = imports.misc.extensionUtils;
|
||||
const ExtensionSystem = imports.ui.extensionSystem;
|
||||
const Mainloop = imports.mainloop;
|
||||
const Signals = imports.signals;
|
||||
|
||||
const Me = ExtensionUtils.getCurrentExtension();
|
||||
const Convenience = Me.imports.convenience;
|
||||
const PanelManager = Me.imports.panelManager;
|
||||
const Utils = Me.imports.utils;
|
||||
|
||||
const UBUNTU_DOCK_UUID = 'ubuntu-dock@ubuntu.com';
|
||||
|
||||
let panelManager;
|
||||
@@ -43,6 +42,7 @@ let settings;
|
||||
let oldDash;
|
||||
let extensionChangedHandler;
|
||||
let disabledUbuntuDock;
|
||||
let extensionSystem = (Main.extensionManager || imports.ui.extensionSystem);
|
||||
|
||||
function init() {
|
||||
Convenience.initTranslations(Utils.TRANSLATION_DOMAIN);
|
||||
@@ -50,7 +50,7 @@ function init() {
|
||||
|
||||
function enable() {
|
||||
// The Ubuntu Dock extension might get enabled after this extension
|
||||
extensionChangedHandler = (Main.extensionManager || ExtensionSystem).connect('extension-state-changed', (data, extension) => {
|
||||
extensionChangedHandler = extensionSystem.connect('extension-state-changed', (data, extension) => {
|
||||
if (extension.uuid === UBUNTU_DOCK_UUID && extension.state === 1) {
|
||||
_enable();
|
||||
}
|
||||
@@ -70,11 +70,13 @@ function _enable() {
|
||||
|
||||
if (ubuntuDock && ubuntuDock.stateObj && ubuntuDock.stateObj.dockManager) {
|
||||
// Disable Ubuntu Dock
|
||||
let extensionOrder = (extensionSystem.extensionOrder || extensionSystem._extensionOrder);
|
||||
|
||||
St.ThemeContext.get_for_stage(global.stage).get_theme().unload_stylesheet(ubuntuDock.stylesheet);
|
||||
ubuntuDock.stateObj.disable();
|
||||
disabledUbuntuDock = true;
|
||||
ubuntuDock.state = ExtensionSystem.ExtensionState.DISABLED;
|
||||
ExtensionSystem.extensionOrder.splice(ExtensionSystem.extensionOrder.indexOf(UBUNTU_DOCK_UUID), 1);
|
||||
ubuntuDock.state = 2; //ExtensionState.DISABLED
|
||||
extensionOrder.splice(extensionOrder.indexOf(UBUNTU_DOCK_UUID), 1);
|
||||
|
||||
//reset to prevent conflicts with the ubuntu-dock
|
||||
if (panelManager) {
|
||||
@@ -125,12 +127,12 @@ function disable(reset) {
|
||||
);
|
||||
|
||||
if (!reset) {
|
||||
ExtensionSystem.disconnect(extensionChangedHandler);
|
||||
extensionSystem.disconnect(extensionChangedHandler);
|
||||
delete global.dashToPanel;
|
||||
|
||||
// Re-enable Ubuntu Dock if it exists and if it was disabled by dash to panel
|
||||
if (disabledUbuntuDock && ExtensionUtils.extensions[UBUNTU_DOCK_UUID] && Main.sessionMode.allowExtensions) {
|
||||
ExtensionSystem.enableExtension(UBUNTU_DOCK_UUID);
|
||||
// Re-enable Ubuntu Dock if it was disabled by dash to panel
|
||||
if (disabledUbuntuDock && Main.sessionMode.allowExtensions) {
|
||||
extensionSystem.enableExtension(UBUNTU_DOCK_UUID);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -41,6 +41,7 @@ const MIN_UPDATE_MS = 250;
|
||||
const T1 = 'checkGrabTimeout';
|
||||
const T2 = 'limitUpdateTimeout';
|
||||
const T3 = 'postAnimateTimeout';
|
||||
const T4 = 'panelBoxClipTimeout';
|
||||
|
||||
var Hold = {
|
||||
NONE: 0,
|
||||
@@ -65,12 +66,12 @@ var Intellihide = Utils.defineClass({
|
||||
this._intellihideChangedId = this._dtpSettings.connect('changed::intellihide', () => this._changeEnabledStatus());
|
||||
this._intellihideOnlySecondaryChangedId = this._dtpSettings.connect('changed::intellihide-only-secondary', () => this._changeEnabledStatus());
|
||||
|
||||
this._enabled = false;
|
||||
this.enabled = false;
|
||||
this._changeEnabledStatus();
|
||||
},
|
||||
|
||||
enable: function(reset) {
|
||||
this._enabled = true;
|
||||
this.enabled = true;
|
||||
this._monitor = this._dtpPanel.monitor;
|
||||
this._animationDestination = -1;
|
||||
this._pendingUpdate = false;
|
||||
@@ -117,14 +118,14 @@ var Intellihide = Utils.defineClass({
|
||||
|
||||
this._revealPanel(!reset);
|
||||
|
||||
this._enabled = false;
|
||||
this.enabled = false;
|
||||
},
|
||||
|
||||
destroy: function() {
|
||||
this._dtpSettings.disconnect(this._intellihideChangedId);
|
||||
this._dtpSettings.disconnect(this._intellihideOnlySecondaryChangedId);
|
||||
|
||||
if (this._enabled) {
|
||||
if (this.enabled) {
|
||||
this.disable();
|
||||
}
|
||||
},
|
||||
@@ -134,7 +135,7 @@ var Intellihide = Utils.defineClass({
|
||||
},
|
||||
|
||||
revealAndHold: function(holdStatus) {
|
||||
if (this._enabled && !this._holdStatus) {
|
||||
if (this.enabled && !this._holdStatus) {
|
||||
this._revealPanel();
|
||||
}
|
||||
|
||||
@@ -144,7 +145,7 @@ var Intellihide = Utils.defineClass({
|
||||
release: function(holdStatus) {
|
||||
this._holdStatus -= holdStatus;
|
||||
|
||||
if (this._enabled && !this._holdStatus) {
|
||||
if (this.enabled && !this._holdStatus) {
|
||||
this._queueUpdatePanelPosition();
|
||||
}
|
||||
},
|
||||
@@ -159,7 +160,7 @@ var Intellihide = Utils.defineClass({
|
||||
let onlySecondary = this._dtpSettings.get_boolean('intellihide-only-secondary');
|
||||
let enabled = intellihide && (this._dtpPanel.isSecondary || !onlySecondary);
|
||||
|
||||
if (this._enabled !== enabled) {
|
||||
if (this.enabled !== enabled) {
|
||||
this[enabled ? 'enable' : 'disable']();
|
||||
}
|
||||
},
|
||||
@@ -221,13 +222,13 @@ var Intellihide = Utils.defineClass({
|
||||
this._clipContainer = new Clutter.Actor();
|
||||
Utils.setClip(this._clipContainer, this._panelBox.x, this._panelBox.y, this._panelBox.width, this._panelBox.height);
|
||||
|
||||
Main.layoutManager.uiGroup.remove_actor(this._panelBox);
|
||||
this._panelBox.show();
|
||||
this._clipContainer.add_child(this._panelBox);
|
||||
this._panelBox.set_position(0, 0);
|
||||
|
||||
Main.layoutManager.removeChrome(this._panelBox);
|
||||
Main.layoutManager.addChrome(this._clipContainer, { affectsInputRegion: false });
|
||||
|
||||
this._clipContainer.add_child(this._panelBox);
|
||||
Main.layoutManager.trackChrome(this._panelBox, { affectsInputRegion: true });
|
||||
|
||||
this._timeoutsHandler.add([T4, 0, () => this._panelBox.set_position(0, 0)]);
|
||||
} else {
|
||||
this._panelBox.set_position(this._clipContainer.x, this._clipContainer.y);
|
||||
Main.layoutManager.removeChrome(this._clipContainer);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"uuid": "dash-to-panel@jderose9.github.com",
|
||||
"name": "Dash to Panel",
|
||||
"description": "An icon taskbar for the Gnome Shell. This extension moves the dash into the gnome main panel so that the application launchers and system tray are combined into a single panel, similar to that found in KDE Plasma and Windows 7+. A separate dock is no longer needed for easy access to running and favorited applications.\n\nFor a more traditional experience, you may also want to use Tweak Tool to enable Windows > Titlebar Buttons > Minimize & Maximize.\n\nFor the best support, please report any issues on Github. Dash-to-panel is developed and maintained by @jderose9 and @charlesg99.",
|
||||
"shell-version": [ "3.18", "3.20", "3.22", "3.24", "3.26", "3.28", "3.30", "3.32" ],
|
||||
"shell-version": [ "3.18", "3.20", "3.22", "3.24", "3.26", "3.28", "3.30", "3.32", "3.34" ],
|
||||
"url": "https://github.com/jderose9/dash-to-panel",
|
||||
"gettext-domain": "dash-to-panel",
|
||||
"version": 9999
|
||||
|
||||
24
overview.js
24
overview.js
@@ -53,15 +53,21 @@ var dtpOverview = Utils.defineClass({
|
||||
this._injectionsHandler = new Utils.InjectionsHandler();
|
||||
this._signalsHandler = new Utils.GlobalSignalsHandler();
|
||||
|
||||
this._isolation = this._optionalWorkspaceIsolation();
|
||||
this._optionalWorkspaceIsolation();
|
||||
this._optionalHotKeys();
|
||||
this._optionalNumberOverlay();
|
||||
this._toggleDash();
|
||||
this._stockgsKeepDashId = this._dtpSettings.connect('changed::stockgs-keep-dash', () => this._toggleDash());
|
||||
|
||||
this._signalsHandler.add([
|
||||
this._dtpSettings,
|
||||
'changed::stockgs-keep-dash',
|
||||
() => this._toggleDash()
|
||||
]);
|
||||
},
|
||||
|
||||
disable: function () {
|
||||
this._dtpSettings.disconnect(this._stockgsKeepDashId);
|
||||
this._signalsHandler.destroy();
|
||||
this._injectionsHandler.destroy();
|
||||
|
||||
this._toggleDash(true);
|
||||
|
||||
@@ -71,8 +77,6 @@ var dtpOverview = Utils.defineClass({
|
||||
// Remove key bindings
|
||||
this._disableHotKeys();
|
||||
this._disableExtraShortcut();
|
||||
|
||||
this._isolation.disable.apply(this);
|
||||
},
|
||||
|
||||
_toggleDash: function(visible) {
|
||||
@@ -101,10 +105,9 @@ var dtpOverview = Utils.defineClass({
|
||||
* Isolate overview to open new windows for inactive apps
|
||||
*/
|
||||
_optionalWorkspaceIsolation: function() {
|
||||
|
||||
let label = 'optionalWorkspaceIsolation';
|
||||
|
||||
this._signalsHandler.addWithLabel(label, [
|
||||
|
||||
this._signalsHandler.add([
|
||||
this._dtpSettings,
|
||||
'changed::isolate-workspaces',
|
||||
Lang.bind(this, function() {
|
||||
@@ -141,9 +144,6 @@ var dtpOverview = Utils.defineClass({
|
||||
function disable() {
|
||||
this._signalsHandler.removeWithLabel(label);
|
||||
this._injectionsHandler.removeWithLabel(label);
|
||||
|
||||
this._signalsHandler.destroy();
|
||||
this._injectionsHandler.destroy();
|
||||
}
|
||||
|
||||
function IsolatedOverview() {
|
||||
@@ -159,8 +159,6 @@ var dtpOverview = Utils.defineClass({
|
||||
return Main.activateWindow(windows[0]);
|
||||
return this.open_new_window(-1);
|
||||
}
|
||||
|
||||
return { disable: disable };
|
||||
},
|
||||
|
||||
// Hotkeys
|
||||
|
||||
53
panel.js
53
panel.js
@@ -83,6 +83,10 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
this.container = this.panel._leftBox;
|
||||
}
|
||||
this.appMenu = this.panel.statusArea.appMenu;
|
||||
|
||||
if (this.panel.statusArea.aggregateMenu) {
|
||||
this.panel.statusArea.aggregateMenu._volume.indicators._dtpIgnoreScroll = 1;
|
||||
}
|
||||
|
||||
this._oldPanelActorDelegate = this.panel.actor._delegate;
|
||||
this.panel.actor._delegate = this;
|
||||
@@ -237,6 +241,11 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
this.panel._centerBox,
|
||||
'actor-added',
|
||||
() => this._setClockLocation(this._dtpSettings.get_string('location-clock'))
|
||||
],
|
||||
[
|
||||
this.panel.actor,
|
||||
'scroll-event',
|
||||
this._onPanelMouseScroll.bind(this)
|
||||
]
|
||||
);
|
||||
|
||||
@@ -283,6 +292,11 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
this._showDesktopTimeoutId = 0;
|
||||
}
|
||||
|
||||
if (this._scrollPanelDelayTimeoutId) {
|
||||
Mainloop.source_remove(this._scrollPanelDelayTimeoutId);
|
||||
this._scrollPanelDelayTimeoutId = 0;
|
||||
}
|
||||
|
||||
if (this.startDynamicTransparencyId) {
|
||||
Mainloop.source_remove(this.startDynamicTransparencyId);
|
||||
this.startDynamicTransparencyId = 0;
|
||||
@@ -336,6 +350,10 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
Utils.hookVfunc(this.panel.__proto__, 'allocate', this.panel.__proto__.vfunc_allocate);
|
||||
}
|
||||
|
||||
if (this.panel.statusArea.aggregateMenu) {
|
||||
delete this.panel.statusArea.aggregateMenu._volume.indicators._dtpIgnoreScroll;
|
||||
}
|
||||
|
||||
this.panel._leftBox.allocate = this.panel._leftBox.oldLeftBoxAllocate;
|
||||
delete this.panel._leftBox.oldLeftBoxAllocate;
|
||||
|
||||
@@ -517,6 +535,7 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
_setPanelPosition: function() {
|
||||
let scaleFactor = St.ThemeContext.get_for_stage(global.stage).scale_factor;
|
||||
let size = this._dtpSettings.get_int('panel-size');
|
||||
let container = this.intellihide && this.intellihide.enabled ? this.panelBox.get_parent() : this.panelBox;
|
||||
|
||||
if(scaleFactor)
|
||||
size = size*scaleFactor;
|
||||
@@ -530,7 +549,7 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
this._myPanelGhost.set_height(isTop ? 0 : size);
|
||||
|
||||
if(isTop) {
|
||||
this.panelBox.set_position(this.monitor.x, this.monitor.y);
|
||||
container.set_position(this.monitor.x, this.monitor.y);
|
||||
|
||||
this._removeTopLimit();
|
||||
|
||||
@@ -541,7 +560,7 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
if(!this.panel.actor.has_style_class_name('dashtopanelTop'))
|
||||
this.panel.actor.add_style_class_name('dashtopanelTop');
|
||||
} else {
|
||||
this.panelBox.set_position(this.monitor.x, this.monitor.y + this.monitor.height - this.panelBox.height);
|
||||
container.set_position(this.monitor.x, this.monitor.y + this.monitor.height - this.panelBox.height);
|
||||
|
||||
if (!this._topLimit) {
|
||||
this._topLimit = new St.BoxLayout({ name: 'topLimit', vertical: true });
|
||||
@@ -735,6 +754,30 @@ var dtpPanelWrapper = Utils.defineClass({
|
||||
|
||||
Main.overview.hide();
|
||||
},
|
||||
|
||||
_onPanelMouseScroll: function(actor, event) {
|
||||
let scrollAction = this._dtpSettings.get_string('scroll-panel-action');
|
||||
let direction = Utils.getMouseScrollDirection(event);
|
||||
|
||||
if (!event.get_source()._dtpIgnoreScroll && direction && !this._scrollPanelDelayTimeoutId) {
|
||||
this._scrollPanelDelayTimeoutId = Mainloop.timeout_add(this._dtpSettings.get_int('scroll-panel-delay'), () => {
|
||||
this._scrollPanelDelayTimeoutId = 0;
|
||||
});
|
||||
|
||||
if (scrollAction === 'SWITCH_WORKSPACE') {
|
||||
let args = [global.display];
|
||||
|
||||
//gnome-shell < 3.30 needs an additional "screen" param
|
||||
global.screen ? args.push(global.screen) : 0;
|
||||
|
||||
Main.wm._showWorkspaceSwitcher.apply(Main.wm, args.concat([0, { get_name: () => 'switch---' + direction }]));
|
||||
} else if (scrollAction === 'CYCLE_WINDOWS') {
|
||||
let windows = this.taskbar.getAppInfos().reduce((ws, appInfo) => ws.concat(appInfo.windows), []);
|
||||
|
||||
Utils.activateSiblingWindow(windows, direction);
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
var dtpSecondaryPanel = Utils.defineClass({
|
||||
@@ -841,15 +884,15 @@ var dtpSecondaryPanel = Utils.defineClass({
|
||||
},
|
||||
|
||||
//next 3 functions are needed by other extensions to add elements to the secondary panel
|
||||
addToStatusArea(role, indicator, position, box) {
|
||||
addToStatusArea: function(role, indicator, position, box) {
|
||||
return Main.panel.addToStatusArea.call(this, role, indicator, position, box);
|
||||
},
|
||||
|
||||
_addToPanelBox(role, indicator, position, box) {
|
||||
_addToPanelBox: function(role, indicator, position, box) {
|
||||
Main.panel._addToPanelBox.call(this, role, indicator, position, box);
|
||||
},
|
||||
|
||||
_onMenuSet(indicator) {
|
||||
_onMenuSet: function(indicator) {
|
||||
Main.panel._onMenuSet.call(this, indicator);
|
||||
},
|
||||
});
|
||||
|
||||
@@ -55,6 +55,8 @@ var dtpPanelManager = Utils.defineClass({
|
||||
_init: function(settings) {
|
||||
this._dtpSettings = settings;
|
||||
this.overview = new Overview.dtpOverview(settings);
|
||||
|
||||
Main.overview.viewSelector.appDisplay._views.forEach(v => Utils.wrapActor(v.view._grid));
|
||||
},
|
||||
|
||||
enable: function(reset) {
|
||||
|
||||
977
po/zh_TW.po
977
po/zh_TW.po
File diff suppressed because it is too large
Load Diff
112
prefs.js
112
prefs.js
@@ -1001,14 +1001,7 @@ const Settings = new Lang.Class({
|
||||
'active',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
|
||||
switch (this._settings.get_string('window-preview-title-position')) {
|
||||
case 'BOTTOM':
|
||||
this._builder.get_object('preview_title_position_bottom_button').set_active(true);
|
||||
break;
|
||||
case 'TOP':
|
||||
this._builder.get_object('preview_title_position_top_button').set_active(true);
|
||||
break;
|
||||
}
|
||||
this._setPreviewTitlePosition();
|
||||
|
||||
this._builder.get_object('grid_preview_title_font_color_colorbutton').connect('notify::color', Lang.bind(this, function (button) {
|
||||
let rgba = button.get_rgba();
|
||||
@@ -1108,6 +1101,11 @@ const Settings = new Lang.Class({
|
||||
this._settings.set_int('leave-timeout', widget.get_value());
|
||||
}));
|
||||
|
||||
this._settings.bind('window-preview-hide-immediate-click',
|
||||
this._builder.get_object('preview_immediate_click_button'),
|
||||
'active',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
|
||||
this._builder.get_object('animation_time_spinbutton').set_value(this._settings.get_int('window-preview-animation-time'));
|
||||
this._builder.get_object('animation_time_spinbutton').connect('value-changed', Lang.bind (this, function(widget) {
|
||||
this._settings.set_int('window-preview-animation-time', widget.get_value());
|
||||
@@ -1163,6 +1161,8 @@ const Settings = new Lang.Class({
|
||||
this._settings.set_value('leave-timeout', this._settings.get_default_value('leave-timeout'));
|
||||
this._builder.get_object('leave_timeout_spinbutton').set_value(this._settings.get_int('leave-timeout'));
|
||||
|
||||
this._settings.set_value('window-preview-hide-immediate-click', this._settings.get_default_value('window-preview-hide-immediate-click'));
|
||||
|
||||
this._settings.set_value('window-preview-animation-time', this._settings.get_default_value('window-preview-animation-time'));
|
||||
this._builder.get_object('animation_time_spinbutton').set_value(this._settings.get_int('window-preview-animation-time'));
|
||||
|
||||
@@ -1171,6 +1171,9 @@ const Settings = new Lang.Class({
|
||||
this._settings.set_value('preview-custom-opacity', this._settings.get_default_value('preview-custom-opacity'));
|
||||
this._builder.get_object('preview_custom_opacity_spinbutton').set_value(this._settings.get_int('preview-custom-opacity'));
|
||||
|
||||
this._settings.set_value('window-preview-title-position', this._settings.get_default_value('window-preview-title-position'));
|
||||
this._setPreviewTitlePosition();
|
||||
|
||||
this._settings.set_value('peek-mode', this._settings.get_default_value('peek-mode'));
|
||||
this._settings.set_value('window-preview-show-title', this._settings.get_default_value('window-preview-show-title'));
|
||||
this._settings.set_value('enter-peek-mode-timeout', this._settings.get_default_value('enter-peek-mode-timeout'));
|
||||
@@ -1393,6 +1396,88 @@ const Settings = new Lang.Class({
|
||||
|
||||
}));
|
||||
|
||||
this._builder.get_object('scroll_panel_combo').set_active_id(this._settings.get_string('scroll-panel-action'));
|
||||
this._builder.get_object('scroll_panel_combo').connect('changed', Lang.bind (this, function(widget) {
|
||||
this._settings.set_string('scroll-panel-action', widget.get_active_id());
|
||||
}));
|
||||
|
||||
this._builder.get_object('scroll_icon_combo').set_active_id(this._settings.get_string('scroll-icon-action'));
|
||||
this._builder.get_object('scroll_icon_combo').connect('changed', Lang.bind (this, function(widget) {
|
||||
this._settings.set_string('scroll-icon-action', widget.get_active_id());
|
||||
}));
|
||||
|
||||
// Create dialog for panel scroll options
|
||||
this._builder.get_object('scroll_panel_options_button').connect('clicked', Lang.bind(this, function() {
|
||||
let dialog = new Gtk.Dialog({ title: _('Customize panel scroll behavior'),
|
||||
transient_for: this.widget.get_toplevel(),
|
||||
use_header_bar: true,
|
||||
modal: true });
|
||||
|
||||
// GTK+ leaves positive values for application-defined response ids.
|
||||
// Use +1 for the reset action
|
||||
dialog.add_button(_('Reset to defaults'), 1);
|
||||
|
||||
let box = this._builder.get_object('scroll_panel_options_box');
|
||||
dialog.get_content_area().add(box);
|
||||
|
||||
this._builder.get_object('scroll_panel_options_delay_spinbutton').set_value(this._settings.get_int('scroll-panel-delay'));
|
||||
this._builder.get_object('scroll_panel_options_delay_spinbutton').connect('value-changed', Lang.bind (this, function(widget) {
|
||||
this._settings.set_int('scroll-panel-delay', widget.get_value());
|
||||
}));
|
||||
|
||||
dialog.connect('response', Lang.bind(this, function(dialog, id) {
|
||||
if (id == 1) {
|
||||
// restore default settings
|
||||
this._settings.set_value('scroll-panel-delay', this._settings.get_default_value('scroll-panel-delay'));
|
||||
this._builder.get_object('scroll_panel_options_delay_spinbutton').set_value(this._settings.get_int('scroll-panel-delay'));
|
||||
} else {
|
||||
// remove the settings box so it doesn't get destroyed;
|
||||
dialog.get_content_area().remove(box);
|
||||
dialog.destroy();
|
||||
}
|
||||
return;
|
||||
}));
|
||||
|
||||
dialog.show_all();
|
||||
|
||||
}));
|
||||
|
||||
// Create dialog for icon scroll options
|
||||
this._builder.get_object('scroll_icon_options_button').connect('clicked', Lang.bind(this, function() {
|
||||
let dialog = new Gtk.Dialog({ title: _('Customize icon scroll behavior'),
|
||||
transient_for: this.widget.get_toplevel(),
|
||||
use_header_bar: true,
|
||||
modal: true });
|
||||
|
||||
// GTK+ leaves positive values for application-defined response ids.
|
||||
// Use +1 for the reset action
|
||||
dialog.add_button(_('Reset to defaults'), 1);
|
||||
|
||||
let box = this._builder.get_object('scroll_icon_options_box');
|
||||
dialog.get_content_area().add(box);
|
||||
|
||||
this._builder.get_object('scroll_icon_options_delay_spinbutton').set_value(this._settings.get_int('scroll-icon-delay'));
|
||||
this._builder.get_object('scroll_icon_options_delay_spinbutton').connect('value-changed', Lang.bind (this, function(widget) {
|
||||
this._settings.set_int('scroll-icon-delay', widget.get_value());
|
||||
}));
|
||||
|
||||
dialog.connect('response', Lang.bind(this, function(dialog, id) {
|
||||
if (id == 1) {
|
||||
// restore default settings
|
||||
this._settings.set_value('scroll-icon-delay', this._settings.get_default_value('scroll-icon-delay'));
|
||||
this._builder.get_object('scroll_icon_options_delay_spinbutton').set_value(this._settings.get_int('scroll-icon-delay'));
|
||||
} else {
|
||||
// remove the settings box so it doesn't get destroyed;
|
||||
dialog.get_content_area().remove(box);
|
||||
dialog.destroy();
|
||||
}
|
||||
return;
|
||||
}));
|
||||
|
||||
dialog.show_all();
|
||||
|
||||
}));
|
||||
|
||||
this._settings.bind('hot-keys',
|
||||
this._builder.get_object('hot_keys_switch'),
|
||||
'active',
|
||||
@@ -1661,6 +1746,17 @@ const Settings = new Lang.Class({
|
||||
});
|
||||
},
|
||||
|
||||
_setPreviewTitlePosition: function() {
|
||||
switch (this._settings.get_string('window-preview-title-position')) {
|
||||
case 'BOTTOM':
|
||||
this._builder.get_object('preview_title_position_bottom_button').set_active(true);
|
||||
break;
|
||||
case 'TOP':
|
||||
this._builder.get_object('preview_title_position_top_button').set_active(true);
|
||||
break;
|
||||
}
|
||||
},
|
||||
|
||||
_showFileChooser: function(title, params, acceptBtn, acceptHandler) {
|
||||
let dialog = new Gtk.FileChooserDialog(mergeObjects({ title: title, transient_for: this.widget.get_toplevel() }, params));
|
||||
|
||||
|
||||
@@ -18,6 +18,11 @@
|
||||
<value value='5' nick='QUIT'/>
|
||||
<value value='6' nick='TOGGLE-SHOWPREVIEW'/>
|
||||
</enum>
|
||||
<enum id='org.gnome.shell.extensions.dash-to-panel.scrollAction'>
|
||||
<value value='0' nick='NOTHING'/>
|
||||
<value value='1' nick='SWITCH_WORKSPACE'/>
|
||||
<value value='2' nick='CYCLE_WINDOWS'/>
|
||||
</enum>
|
||||
<enum id='org.gnome.shell.extensions.dash-to-panel.statusAreaPosition'>
|
||||
<value value='0' nick='BUTTONSLEFT'/>
|
||||
<value value='1' nick='STATUSLEFT'/>
|
||||
@@ -466,6 +471,11 @@
|
||||
<summary>Aspect ratio Y</summary>
|
||||
<description>The window previews respected aspect ratio Y.</description>
|
||||
</key>
|
||||
<key type="b" name="window-preview-hide-immediate-click">
|
||||
<default>false</default>
|
||||
<summary>Immediate hide on icon click</summary>
|
||||
<description>The window previews immediately hide when an application icon is clicked.</description>
|
||||
</key>
|
||||
<key type="b" name="isolate-workspaces">
|
||||
<default>false</default>
|
||||
<summary>Provide workspace isolation</summary>
|
||||
@@ -574,6 +584,26 @@
|
||||
<summary>Action when clicking on a running app</summary>
|
||||
<description>Set the action that is executed when shift+middle-clicking on the icon of a running application</description>
|
||||
</key>
|
||||
<key name="scroll-panel-action" enum="org.gnome.shell.extensions.dash-to-panel.scrollAction">
|
||||
<default>'SWITCH_WORKSPACE'</default>
|
||||
<summary>Action when scrolling over the panel</summary>
|
||||
<description>Set the action that is executed when scrolling over the panel</description>
|
||||
</key>
|
||||
<key type="i" name="scroll-panel-delay">
|
||||
<default>0</default>
|
||||
<summary>Delay between panel mouse scroll events</summary>
|
||||
<description>Set the minimum delay between panel mouse scroll events</description>
|
||||
</key>
|
||||
<key name="scroll-icon-action" enum="org.gnome.shell.extensions.dash-to-panel.scrollAction">
|
||||
<default>'CYCLE_WINDOWS'</default>
|
||||
<summary>Action when scrolling over a running app</summary>
|
||||
<description>Set the action that is executed when scrolling over a running application</description>
|
||||
</key>
|
||||
<key type="i" name="scroll-icon-delay">
|
||||
<default>0</default>
|
||||
<summary>Delay between icon mouse scroll events</summary>
|
||||
<description>Set the minimum delay between icon mouse scroll events</description>
|
||||
</key>
|
||||
<key type="i" name="leave-timeout">
|
||||
<default>100</default>
|
||||
<summary>Icon leave preview timeout</summary>
|
||||
|
||||
42
taskbar.js
42
taskbar.js
@@ -48,9 +48,7 @@ const Utils = Me.imports.utils;
|
||||
const WindowPreview = Me.imports.windowPreview;
|
||||
const AppIcons = Me.imports.appIcons;
|
||||
|
||||
var DASH_ANIMATION_TIME = Dash.DASH_ANIMATION_TIME;
|
||||
let DASH_ITEM_LABEL_SHOW_TIME = Dash.DASH_ITEM_LABEL_SHOW_TIME;
|
||||
let DASH_ITEM_LABEL_HIDE_TIME = Dash.DASH_ITEM_LABEL_HIDE_TIME;
|
||||
var DASH_ANIMATION_TIME = Dash.DASH_ANIMATION_TIME / (Dash.DASH_ANIMATION_TIME > 1 ? 1000 : 1);
|
||||
var DASH_ITEM_HOVER_TIMEOUT = Dash.DASH_ITEM_HOVER_TIMEOUT;
|
||||
var MIN_ICON_SIZE = 4;
|
||||
|
||||
@@ -363,7 +361,10 @@ var taskbar = Utils.defineClass({
|
||||
this._showAppsIconWrapper.destroy();
|
||||
|
||||
this._container.destroy();
|
||||
|
||||
this.previewMenu.disable();
|
||||
this.previewMenu.destroy();
|
||||
|
||||
this._disconnectWorkspaceSignals();
|
||||
},
|
||||
|
||||
@@ -739,13 +740,7 @@ var taskbar = Utils.defineClass({
|
||||
getAppStableSequence(appB, this._dtpSettings, this.panelWrapper.monitor);
|
||||
},
|
||||
|
||||
_redisplay: function () {
|
||||
if (!this._signalsHandler) {
|
||||
return;
|
||||
}
|
||||
|
||||
//get the currently displayed appIcons
|
||||
let currentAppIcons = this._getTaskbarIcons();
|
||||
getAppInfos: function() {
|
||||
//get the user's favorite apps
|
||||
let favoriteApps = this._checkIfShowingFavorites() ? AppFavorites.getAppFavorites().getFavorites() : [];
|
||||
|
||||
@@ -753,16 +748,25 @@ var taskbar = Utils.defineClass({
|
||||
// When using isolation, we filter out apps that have no windows in
|
||||
// the current workspace (this check is done in AppIcons.getInterestingWindows)
|
||||
let runningApps = this._checkIfShowingRunningApps() ? this._getRunningApps().sort(this.sortAppsCompareFunction.bind(this)) : [];
|
||||
let expectedAppInfos;
|
||||
|
||||
|
||||
if (!this.isGroupApps && this._dtpSettings.get_boolean('group-apps-use-launchers')) {
|
||||
expectedAppInfos = this._createAppInfos(favoriteApps, [], true)
|
||||
.concat(this._createAppInfos(runningApps)
|
||||
.filter(appInfo => appInfo.windows.length));
|
||||
return this._createAppInfos(favoriteApps, [], true)
|
||||
.concat(this._createAppInfos(runningApps)
|
||||
.filter(appInfo => appInfo.windows.length));
|
||||
} else {
|
||||
expectedAppInfos = this._createAppInfos(favoriteApps.concat(runningApps.filter(app => favoriteApps.indexOf(app) < 0)))
|
||||
.filter(appInfo => appInfo.windows.length || favoriteApps.indexOf(appInfo.app) >= 0);
|
||||
return this._createAppInfos(favoriteApps.concat(runningApps.filter(app => favoriteApps.indexOf(app) < 0)))
|
||||
.filter(appInfo => appInfo.windows.length || favoriteApps.indexOf(appInfo.app) >= 0);
|
||||
}
|
||||
},
|
||||
|
||||
_redisplay: function () {
|
||||
if (!this._signalsHandler) {
|
||||
return;
|
||||
}
|
||||
|
||||
//get the currently displayed appIcons
|
||||
let currentAppIcons = this._getTaskbarIcons();
|
||||
let expectedAppInfos = this.getAppInfos();
|
||||
|
||||
//remove the appIcons which are not in the expected apps list
|
||||
for (let i = currentAppIcons.length - 1; i > -1; --i) {
|
||||
@@ -961,9 +965,9 @@ var taskbar = Utils.defineClass({
|
||||
// Ensure the next and previous icon are visible when moving the icon
|
||||
// (I assume there's room for both of them)
|
||||
if (hoveredIndex > 1)
|
||||
ensureActorVisibleInScrollView(this._scrollView, this._box.get_children()[hoveredIndex-1], this._scrollView._dtpFadeSize);
|
||||
Utils.ensureActorVisibleInScrollView(this._scrollView, this._box.get_children()[hoveredIndex-1], this._scrollView._dtpFadeSize);
|
||||
if (hoveredIndex < this._box.get_children().length-1)
|
||||
ensureActorVisibleInScrollView(this._scrollView, this._box.get_children()[hoveredIndex+1], this._scrollView._dtpFadeSize);
|
||||
Utils.ensureActorVisibleInScrollView(this._scrollView, this._box.get_children()[hoveredIndex+1], this._scrollView._dtpFadeSize);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
34
utils.js
34
utils.js
@@ -380,6 +380,40 @@ var getrgbaColor = function(color, alpha, offset) {
|
||||
return 'rgba(' + rgb.red + ',' + rgb.green + ',' + rgb.blue + ',' + (Math.floor(alpha * 100) * 0.01) + '); ' ;
|
||||
};
|
||||
|
||||
var getMouseScrollDirection = function(event) {
|
||||
let direction;
|
||||
|
||||
switch (event.get_scroll_direction()) {
|
||||
case Clutter.ScrollDirection.UP:
|
||||
case Clutter.ScrollDirection.LEFT:
|
||||
direction = 'up';
|
||||
break;
|
||||
case Clutter.ScrollDirection.DOWN:
|
||||
case Clutter.ScrollDirection.RIGHT:
|
||||
direction = 'down';
|
||||
break;
|
||||
}
|
||||
|
||||
return direction;
|
||||
};
|
||||
|
||||
var activateSiblingWindow = function(windows, direction, startWindow) {
|
||||
let windowIndex = windows.indexOf(global.display.focus_window);
|
||||
let nextWindowIndex = windowIndex < 0 ?
|
||||
startWindow ? windows.indexOf(startWindow) : 0 :
|
||||
windowIndex + (direction == 'up' ? 1 : -1);
|
||||
|
||||
if (nextWindowIndex == windows.length) {
|
||||
nextWindowIndex = 0;
|
||||
} else if (nextWindowIndex < 0) {
|
||||
nextWindowIndex = windows.length - 1;
|
||||
}
|
||||
|
||||
if (windowIndex != nextWindowIndex) {
|
||||
Main.activateWindow(windows[nextWindowIndex]);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* This is a copy of the same function in utils.js, but also adjust horizontal scrolling
|
||||
* and perform few further cheks on the current value to avoid changing the values when
|
||||
|
||||
@@ -153,10 +153,8 @@ var PreviewMenu = Utils.defineClass({
|
||||
|
||||
this.close(true);
|
||||
|
||||
Main.layoutManager._untrackActor(this);
|
||||
Main.uiGroup.remove_child(this);
|
||||
|
||||
this.destroy();
|
||||
Main.layoutManager.untrackChrome(this.menu);
|
||||
Main.layoutManager.removeChrome(this);
|
||||
},
|
||||
|
||||
requestOpen: function(appIcon) {
|
||||
|
||||
Reference in New Issue
Block a user