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
5ae6e6b6
Commit
5ae6e6b6
authored
Sep 05, 2011
by
Claudio Valerio
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed UBDesktopToolPalette
parent
b264964c
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
0 additions
and
144 deletions
+0
-144
UBDesktopAnnotationController.cpp
src/desktop/UBDesktopAnnotationController.cpp
+0
-23
UBDesktopAnnotationController.h
src/desktop/UBDesktopAnnotationController.h
+0
-3
UBDesktopPalette.cpp
src/desktop/UBDesktopPalette.cpp
+0
-2
UBDesktopToolsPalette.cpp
src/desktop/UBDesktopToolsPalette.cpp
+0
-85
UBDesktopToolsPalette.h
src/desktop/UBDesktopToolsPalette.h
+0
-29
desktop.pri
src/desktop/desktop.pri
+0
-2
No files found.
src/desktop/UBDesktopAnnotationController.cpp
View file @
5ae6e6b6
...
...
@@ -37,7 +37,6 @@
#include "UBCustomCaptureWindow.h"
#include "UBWindowCapture.h"
#include "UBDesktopPalette.h"
#include "UBDesktopToolsPalette.h"
#include "UBDesktopPenPalette.h"
#include "UBDesktopMarkerPalette.h"
#include "UBDesktopEraserPalette.h"
...
...
@@ -52,7 +51,6 @@ UBDesktopAnnotationController::UBDesktopAnnotationController(QObject *parent)
,
mTransparentDrawingScene
(
0
)
,
mDesktopPalette
(
NULL
)
,
mKeyboardPalette
(
0
)
,
mDesktopToolsPalette
(
NULL
)
,
mDesktopPenPalette
(
NULL
)
,
mDesktopMarkerPalette
(
NULL
)
,
mDesktopEraserPalette
(
NULL
)
...
...
@@ -124,7 +122,6 @@ UBDesktopAnnotationController::UBDesktopAnnotationController(QObject *parent)
,
this
,
SLOT
(
stylusToolChanged
(
int
)));
// Add the desktop associated palettes
mDesktopToolsPalette
=
new
UBDesktopToolsPalette
(
mTransparentDrawingView
);
mDesktopPenPalette
=
new
UBDesktopPenPalette
(
mTransparentDrawingView
);
connect
(
mDesktopPalette
,
SIGNAL
(
maximized
()),
mDesktopPenPalette
,
SLOT
(
onParentMaximized
()));
...
...
@@ -134,12 +131,10 @@ UBDesktopAnnotationController::UBDesktopAnnotationController(QObject *parent)
mDesktopEraserPalette
=
new
UBDesktopEraserPalette
(
mTransparentDrawingView
);
mDesktopPalette
->
setBackgroundBrush
(
UBSettings
::
settings
()
->
opaquePaletteColor
);
mDesktopToolsPalette
->
setBackgroundBrush
(
UBSettings
::
settings
()
->
opaquePaletteColor
);
mDesktopPenPalette
->
setBackgroundBrush
(
UBSettings
::
settings
()
->
opaquePaletteColor
);
mDesktopMarkerPalette
->
setBackgroundBrush
(
UBSettings
::
settings
()
->
opaquePaletteColor
);
mDesktopEraserPalette
->
setBackgroundBrush
(
UBSettings
::
settings
()
->
opaquePaletteColor
);
mDesktopToolsPalette
->
setVisible
(
UBApplication
::
mainWindow
->
actionDesktopTools
->
isChecked
());
// Hack : the size of the property palettes is computed the first time the palette is visible
// In order to prevent palette overlap on if the desktop palette is on the right of the
...
...
@@ -151,7 +146,6 @@ UBDesktopAnnotationController::UBDesktopAnnotationController(QObject *parent)
mDesktopMarkerPalette
->
setVisible
(
false
);
mDesktopEraserPalette
->
setVisible
(
false
);
connect
(
UBApplication
::
mainWindow
->
actionDesktopTools
,
SIGNAL
(
triggered
(
bool
)),
this
,
SLOT
(
desktopToolsActionToogled
(
bool
)));
connect
(
UBApplication
::
mainWindow
->
actionEraseDesktopAnnotations
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
eraseDesktopAnnotations
()));
connect
(
&
mHoldTimerPen
,
SIGNAL
(
timeout
()),
this
,
SLOT
(
penActionReleased
()));
...
...
@@ -226,23 +220,6 @@ UBDesktopPalette* UBDesktopAnnotationController::desktopPalette()
return
mDesktopPalette
;
}
void
UBDesktopAnnotationController
::
desktopToolsActionToogled
(
bool
checked
)
{
if
(
!
mDesktopToolsPalettePositioned
)
{
QPoint
pos
=
mDesktopPalette
->
geometry
().
bottomLeft
();
pos
+=
QPoint
(
0
,
10
);
mDesktopToolsPalette
->
setCustomPosition
(
true
);
mDesktopToolsPalette
->
move
(
pos
);
mDesktopToolsPalettePositioned
=
true
;
}
mDesktopToolsPalette
->
setVisible
(
checked
);
}
/**
* \brief Toggle the visibility of the pen associated palette
* @param checked as the visibility state
...
...
src/desktop/UBDesktopAnnotationController.h
View file @
5ae6e6b6
...
...
@@ -23,7 +23,6 @@
#include "gui/UBRightPalette.h"
class
UBDesktopPalette
;
class
UBDesktopToolsPalette
;
class
UBBoardView
;
class
UBGraphicsScene
;
class
UBDesktopPenPalette
;
...
...
@@ -89,7 +88,6 @@ class UBDesktopAnnotationController : public QObject
UBGraphicsScene
*
mTransparentDrawingScene
;
private
slots
:
void
desktopToolsActionToogled
(
bool
);
void
desktopPenActionToggled
(
bool
checked
);
void
desktopMarkerActionToggled
(
bool
checked
);
void
desktopEraserActionToggled
(
bool
checked
);
...
...
@@ -112,7 +110,6 @@ class UBDesktopAnnotationController : public QObject
UBDesktopPalette
*
mDesktopPalette
;
UBKeyboardPalette
*
mKeyboardPalette
;
UBDesktopToolsPalette
*
mDesktopToolsPalette
;
UBDesktopPenPalette
*
mDesktopPenPalette
;
UBDesktopMarkerPalette
*
mDesktopMarkerPalette
;
UBDesktopEraserPalette
*
mDesktopEraserPalette
;
...
...
src/desktop/UBDesktopPalette.cpp
View file @
5ae6e6b6
...
...
@@ -159,8 +159,6 @@ void UBDesktopPalette::maximizeMe()
actions
<<
mDisplaySelectAction
;
actions
<<
mShowHideAction
;
//actions << UBApplication::mainWindow->actionDesktopTools;
setActions
(
actions
);
QSize
newSize
=
preferredSize
();
...
...
src/desktop/UBDesktopToolsPalette.cpp
deleted
100644 → 0
View file @
b264964c
/*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "UBDesktopToolsPalette.h"
#include "core/UBApplication.h"
#include "core/UBSettings.h"
#include "board/UBBoardController.h"
#include "board/UBDrawingController.h"
#include "gui/UBMainWindow.h"
#include "gui/UBToolbarButtonGroup.h"
#include "core/memcheck.h"
UBDesktopToolsPalette
::
UBDesktopToolsPalette
(
QWidget
*
parent
)
:
UBActionPalette
(
Qt
::
Horizontal
,
parent
)
{
// Setup color choice widget
QList
<
QAction
*>
colorActions
;
colorActions
.
append
(
UBApplication
::
mainWindow
->
actionColor0
);
colorActions
.
append
(
UBApplication
::
mainWindow
->
actionColor1
);
colorActions
.
append
(
UBApplication
::
mainWindow
->
actionColor2
);
colorActions
.
append
(
UBApplication
::
mainWindow
->
actionColor3
);
UBToolbarButtonGroup
*
colorChoice
=
new
UBToolbarButtonGroup
(
UBApplication
::
mainWindow
->
boardToolBar
,
colorActions
);
colorChoice
->
displayText
(
false
);
//connect(colorChoice, SIGNAL(activated(int)), this, SLOT(UBApplication::boardController->setColorIndex(int)));
connect
(
UBDrawingController
::
drawingController
(),
SIGNAL
(
colorIndexChanged
(
int
)),
colorChoice
,
SLOT
(
setCurrentIndex
(
int
)));
connect
(
UBDrawingController
::
drawingController
(),
SIGNAL
(
colorPaletteChanged
()),
colorChoice
,
SLOT
(
colorPaletteChanged
()));
layout
()
->
addWidget
(
colorChoice
);
// Setup line width choice widget
QList
<
QAction
*>
lineWidthActions
;
lineWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionLineSmall
);
lineWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionLineMedium
);
lineWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionLineLarge
);
UBToolbarButtonGroup
*
lineWidthChoice
=
new
UBToolbarButtonGroup
(
UBApplication
::
mainWindow
->
boardToolBar
,
lineWidthActions
);
lineWidthChoice
->
displayText
(
false
);
connect
(
lineWidthChoice
,
SIGNAL
(
activated
(
int
))
,
UBDrawingController
::
drawingController
(),
SLOT
(
setLineWidthIndex
(
int
)));
connect
(
UBDrawingController
::
drawingController
(),
SIGNAL
(
lineWidthIndexChanged
(
int
))
,
lineWidthChoice
,
SLOT
(
setCurrentIndex
(
int
)));
layout
()
->
addWidget
(
lineWidthChoice
);
// Setup eraser width choice widget
QList
<
QAction
*>
eraserWidthActions
;
eraserWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionEraserSmall
);
eraserWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionEraserMedium
);
eraserWidthActions
.
append
(
UBApplication
::
mainWindow
->
actionEraserLarge
);
UBToolbarButtonGroup
*
eraserWidthChoice
=
new
UBToolbarButtonGroup
(
UBApplication
::
mainWindow
->
boardToolBar
,
eraserWidthActions
);
connect
(
eraserWidthChoice
,
SIGNAL
(
activated
(
int
)),
UBDrawingController
::
drawingController
(),
SLOT
(
setEraserWidthIndex
(
int
)));
eraserWidthChoice
->
displayText
(
false
);
eraserWidthChoice
->
setCurrentIndex
(
UBSettings
::
settings
()
->
eraserWidthIndex
());
layout
()
->
addWidget
(
eraserWidthChoice
);
addAction
(
UBApplication
::
mainWindow
->
actionEraseDesktopAnnotations
);
}
src/desktop/UBDesktopToolsPalette.h
deleted
100644 → 0
View file @
b264964c
/*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef UBDESKTOPTOOLSPALETTE_H
#define UBDESKTOPTOOLSPALETTE_H
#include <QtGui>
#include "gui/UBActionPalette.h"
class
UBDesktopToolsPalette
:
public
UBActionPalette
{
public
:
UBDesktopToolsPalette
(
QWidget
*
parent
=
0
);
virtual
~
UBDesktopToolsPalette
(){}
};
#endif // UBDESKTOPTOOLSPALETTE_H
src/desktop/desktop.pri
View file @
5ae6e6b6
...
...
@@ -2,7 +2,6 @@ HEADERS += src/desktop/UBDesktopPalette.h \
src/desktop/UBDesktopAnnotationController.h \
src/desktop/UBCustomCaptureWindow.h \
src/desktop/UBWindowCapture.h \
src/desktop/UBDesktopToolsPalette.h \
src/desktop/UBDesktopPenPalette.h \
src/desktop/UBDesktopMarkerPalette.h \
src/desktop/UBDesktopEraserPalette.h
...
...
@@ -10,7 +9,6 @@ HEADERS += src/desktop/UBDesktopPalette.h \
SOURCES += src/desktop/UBDesktopPalette.cpp \
src/desktop/UBDesktopAnnotationController.cpp \
src/desktop/UBCustomCaptureWindow.cpp \
src/desktop/UBDesktopToolsPalette.cpp \
src/desktop/UBDesktopPenPalette.cpp \
src/desktop/UBDesktopMarkerPalette.cpp \
src/desktop/UBDesktopEraserPalette.cpp
...
...
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