Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gajim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mesonium
gajim
Commits
4c930934
Commit
4c930934
authored
4 years ago
by
Philipp Hörist
Browse files
Options
Downloads
Patches
Plain Diff
Save workspace order
parent
1c540528
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
gajim/gtk/main.py
+2
-0
2 additions, 0 deletions
gajim/gtk/main.py
gajim/gtk/workspace_side_bar.py
+6
-0
6 additions, 0 deletions
gajim/gtk/workspace_side_bar.py
with
8 additions
and
0 deletions
gajim/gtk/main.py
+
2
−
0
View file @
4c930934
...
...
@@ -303,6 +303,8 @@ def add_workspace(self, workspace_id):
self
.
_chat_list_stack
.
add_chat_list
(
workspace_id
)
self
.
_workspace_side_bar
.
activate_workspace
(
workspace_id
)
self
.
_chat_list_stack
.
show_chat_list
(
workspace_id
)
if
self
.
_startup_finished
:
self
.
_workspace_side_bar
.
store_workspace_order
()
def
_edit_workspace
(
self
,
_action
,
_param
):
workspace_id
=
self
.
get_active_workspace
()
...
...
This diff is collapsed.
Click to expand it.
gajim/gtk/workspace_side_bar.py
+
6
−
0
View file @
4c930934
...
...
@@ -104,6 +104,7 @@ def _on_drag_data_received(self, _widget, _drag_context, _x_coord,
pos
=
len
(
self
.
get_children
())
-
1
self
.
insert
(
row
,
pos
)
self
.
store_workspace_order
()
app
.
window
.
activate_workspace
(
workspace_id
)
def
_on_drag_leave
(
self
,
_widget
,
_drag_context
,
_time
):
...
...
@@ -147,6 +148,11 @@ def add_workspace(self, workspace_id):
# Insert row before AddWorkspace row
self
.
insert
(
row
,
len
(
self
.
get_children
())
-
1
)
def
store_workspace_order
(
self
):
order
=
[
row
.
workspace_id
for
row
in
self
.
get_children
()]
order
.
remove
(
'
add
'
)
app
.
settings
.
set_app_setting
(
'
workspace_order
'
,
order
)
def
remove_workspace
(
self
,
workspace_id
):
if
len
(
self
.
_workspaces
)
==
1
:
return
False
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment