Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vmj-qt
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
vmj-qt
Commits
d4a70301
Commit
d4a70301
authored
Jun 01, 2010
by
Dan Pascu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Scroll list to selected item after conference DND
parent
dee55690
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
sessions.py
blink/sessions.py
+4
-0
No files found.
blink/sessions.py
View file @
d4a70301
...
@@ -454,6 +454,7 @@ class SessionModel(QAbstractListModel):
...
@@ -454,6 +454,7 @@ class SessionModel(QAbstractListModel):
self
.
endInsertRows
()
self
.
endInsertRows
()
session_list
.
openPersistentEditor
(
self
.
index
(
position
))
session_list
.
openPersistentEditor
(
self
.
index
(
position
))
source
.
conference
=
target
.
conference
source
.
conference
=
target
.
conference
session_list
.
scrollTo
(
self
.
index
(
position
),
session_list
.
EnsureVisible
)
# or PositionAtBottom
else
:
else
:
target_row
=
index
.
row
()
target_row
=
index
.
row
()
first
,
last
=
(
source
,
target
)
if
source_row
<
target_row
else
(
target
,
source
)
first
,
last
=
(
source
,
target
)
if
source_row
<
target_row
else
(
target
,
source
)
...
@@ -468,6 +469,7 @@ class SessionModel(QAbstractListModel):
...
@@ -468,6 +469,7 @@ class SessionModel(QAbstractListModel):
first
.
conference
=
conference
first
.
conference
=
conference
last
.
conference
=
conference
last
.
conference
=
conference
position
=
self
.
sessions
.
index
(
source
)
position
=
self
.
sessions
.
index
(
source
)
session_list
.
scrollToTop
()
session_list
.
setSelectionMode
(
selection_mode
)
session_list
.
setSelectionMode
(
selection_mode
)
selection_model
.
select
(
self
.
index
(
position
),
selection_model
.
Select
)
selection_model
.
select
(
self
.
index
(
position
),
selection_model
.
Select
)
else
:
else
:
...
@@ -488,11 +490,13 @@ class SessionModel(QAbstractListModel):
...
@@ -488,11 +490,13 @@ class SessionModel(QAbstractListModel):
self
.
_add_session
(
first
)
self
.
_add_session
(
first
)
self
.
_add_session
(
last
)
self
.
_add_session
(
last
)
position
=
self
.
sessions
.
index
(
sibling
)
position
=
self
.
sessions
.
index
(
sibling
)
session_list
.
scrollToBottom
()
else
:
else
:
source
.
conference
=
None
source
.
conference
=
None
self
.
_pop_session
(
source
)
self
.
_pop_session
(
source
)
self
.
_add_session
(
source
)
self
.
_add_session
(
source
)
position
=
self
.
sessions
.
index
(
conference
.
sessions
[
0
])
position
=
self
.
sessions
.
index
(
conference
.
sessions
[
0
])
session_list
.
scrollTo
(
self
.
index
(
position
),
session_list
.
PositionAtCenter
)
session_list
.
setSelectionMode
(
selection_mode
)
session_list
.
setSelectionMode
(
selection_mode
)
selection_model
.
select
(
self
.
index
(
position
),
selection_model
.
Select
)
selection_model
.
select
(
self
.
index
(
position
),
selection_model
.
Select
)
return
True
return
True
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment