Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpenBoard
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
lifo
Nicolas Ollinger
OpenBoard
Commits
cf662842
Commit
cf662842
authored
Jun 11, 2012
by
Aleksei Kanash
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved switching between documents. Removed useless calls, some logic changes.
parent
f849bea3
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
7 deletions
+10
-7
UBBoardController.cpp
src/board/UBBoardController.cpp
+3
-2
UBBoardController.h
src/board/UBBoardController.h
+1
-0
UBDocumentNavigator.cpp
src/gui/UBDocumentNavigator.cpp
+6
-4
UBPageNavigationWidget.cpp
src/gui/UBPageNavigationWidget.cpp
+0
-1
No files found.
src/board/UBBoardController.cpp
View file @
cf662842
...
...
@@ -452,6 +452,7 @@ void UBBoardController::addScene()
setActiveDocumentScene
(
mActiveDocument
,
mActiveSceneIndex
+
1
);
QApplication
::
restoreOverrideCursor
();
emit
newPageAdded
();
}
...
...
@@ -1179,11 +1180,11 @@ void UBBoardController::setActiveDocumentScene(UBDocumentProxy* pDocumentProxy,
if
(
documentChange
)
{
emit
activeDocumentChanged
();
// Notify the navigator palette that the document has changed
emit
setDocOnPageNavigator
(
pDocumentProxy
);
UBGraphicsTextItem
::
lastUsedTextColor
=
QColor
();
}
// Notify the navigator palette that the document has changed
emit
setDocOnPageNavigator
(
pDocumentProxy
);
if
(
sceneChange
)
{
...
...
src/board/UBBoardController.h
View file @
cf662842
...
...
@@ -215,6 +215,7 @@ class UBBoardController : public QObject
void
stopScript
();
signals
:
void
newPageAdded
();
void
activeSceneWillBePersisted
();
void
activeSceneWillChange
();
void
activeSceneChanged
();
...
...
src/gui/UBDocumentNavigator.cpp
View file @
cf662842
...
...
@@ -55,10 +55,11 @@ UBDocumentNavigator::UBDocumentNavigator(QWidget *parent, const char *name):QGra
setFrameShadow
(
QFrame
::
Plain
);
connect
(
UBApplication
::
boardController
,
SIGNAL
(
activeSceneChanged
()),
this
,
SLOT
(
addNewPage
()));
connect
(
UBApplication
::
boardController
,
SIGNAL
(
setDocOnPageNavigator
(
UBDocumentProxy
*
)),
this
,
SLOT
(
generateThumbnails
()));
connect
(
UBApplication
::
boardController
,
SIGNAL
(
activeSceneChanged
()),
this
,
SLOT
(
generateThumbnails
()));
connect
(
UBApplication
::
boardController
,
SIGNAL
(
newPageAdded
()),
this
,
SLOT
(
addNewPage
()));
connect
(
mScene
,
SIGNAL
(
selectionChanged
()),
this
,
SLOT
(
onSelectionChanged
()));
connect
(
UBApplication
::
boardController
,
SIGNAL
(
documentReorganized
(
int
)),
this
,
SLOT
(
onMovedToIndex
(
int
)));
connect
(
UBApplication
::
boardController
,
SIGNAL
(
scrollToSelectedPage
()),
this
,
SLOT
(
onScrollToSelectedPage
()));
}
/**
...
...
@@ -150,10 +151,11 @@ void UBDocumentNavigator::updateSpecificThumbnail(int iPage)
if
(
UBApplication
::
boardController
)
{
UBApplication
::
boardController
->
persistCurrentScene
();
}
else
{
UBThumbnailAdaptor
::
persistScene
(
mCrntDoc
->
persistencePath
(),
pScene
,
iPage
);
}
UBThumbnailAdaptor
::
persistScene
(
mCrntDoc
->
persistencePath
(),
pScene
,
iPage
);
// Load it
QPixmap
pix
=
UBThumbnailAdaptor
::
load
(
mCrntDoc
,
iPage
);
UBSceneThumbnailNavigPixmap
*
pixmapItem
=
new
UBSceneThumbnailNavigPixmap
(
pix
,
mCrntDoc
,
iPage
);
...
...
src/gui/UBPageNavigationWidget.cpp
View file @
cf662842
...
...
@@ -115,7 +115,6 @@ void UBPageNavigationWidget::setDocument(UBDocumentProxy *document)
if
(
mNavigator
->
currentDoc
()
!=
document
)
{
mNavigator
->
setDocument
(
document
);
UBApplication
::
boardController
->
notifyPageChanged
();
}
}
...
...
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