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
6b1da4b6
Commit
6b1da4b6
authored
Jan 09, 2012
by
shibakaneki
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'Bett-2012' of github.com:Sankore/Sankore-3.1 into Bett-2012
parents
c3281a2c
c0fefa26
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
53 additions
and
11 deletions
+53
-11
UBWidgetList.cpp
src/customWidgets/UBWidgetList.cpp
+3
-1
UBMediaPlayer.cpp
src/gui/UBMediaPlayer.cpp
+3
-3
UBTeacherBarWidget.cpp
src/gui/UBTeacherBarWidget.cpp
+41
-6
UBTeacherBarWidget.h
src/gui/UBTeacherBarWidget.h
+6
-1
No files found.
src/customWidgets/UBWidgetList.cpp
View file @
6b1da4b6
...
@@ -91,12 +91,14 @@ int UBWidgetList::scaleWidgets(QSize pSize)
...
@@ -91,12 +91,14 @@ int UBWidgetList::scaleWidgets(QSize pSize)
newWidgetWidth
=
mWidgetInfo
[
eachWidget
].
width
()
/
scaleFactor
;
newWidgetWidth
=
mWidgetInfo
[
eachWidget
].
width
()
/
scaleFactor
;
result
+=
newWidgetWidth
;
result
+=
newWidgetWidth
;
}
}
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"widget "
<<
&
eachWidget
;
#ifndef Q_WS_WIN
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"widget "
<<
&
eachWidget
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"count "
<<
count
++
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"count "
<<
count
++
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"widget orignal size "
<<
mWidgetInfo
[
eachWidget
];
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"widget orignal size "
<<
mWidgetInfo
[
eachWidget
];
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"containes size "
<<
pSize
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"containes size "
<<
pSize
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"scale factor "
<<
scaleFactor
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"scale factor "
<<
scaleFactor
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"new height "
<<
result
;
qDebug
()
<<
__PRETTY_FUNCTION__
<<
"new height "
<<
result
;
#endif
}
}
return
result
;
return
result
;
}
}
...
...
src/gui/UBMediaPlayer.cpp
View file @
6b1da4b6
...
@@ -123,9 +123,9 @@ UBMediaPlayer::UBMediaPlayer() :
...
@@ -123,9 +123,9 @@ UBMediaPlayer::UBMediaPlayer() :
#ifdef Q_OS_MAC
#ifdef Q_OS_MAC
// layout->setSpacing(4);
// layout->setSpacing(4);
buttonPanelLayout
->
setSpacing
(
0
);
buttonPanelLayout
->
setSpacing
(
0
);
info
->
setMinimumHeight
(
100
);
//
info->setMinimumHeight(100);
info
->
setFont
(
QFont
(
"verdana"
,
15
));
//
info->setFont(QFont("verdana", 15));
openButton
->
setFocusPolicy
(
Qt
::
NoFocus
);
//
openButton->setFocusPolicy(Qt::NoFocus);
#endif
#endif
QWidget
*
buttonPanelWidget
=
new
QWidget
(
this
);
QWidget
*
buttonPanelWidget
=
new
QWidget
(
this
);
buttonPanelWidget
->
setSizePolicy
(
QSizePolicy
::
Preferred
,
QSizePolicy
::
Fixed
);
buttonPanelWidget
->
setSizePolicy
(
QSizePolicy
::
Preferred
,
QSizePolicy
::
Fixed
);
...
...
src/gui/UBTeacherBarWidget.cpp
View file @
6b1da4b6
...
@@ -386,7 +386,12 @@ void UBTeacherBarWidget::loadContent()
...
@@ -386,7 +386,12 @@ void UBTeacherBarWidget::loadContent()
if
(
!
mUrlList
.
empty
()){
if
(
!
mUrlList
.
empty
()){
QStringList
links
;
QStringList
links
;
foreach
(
UBUrlWidget
*
url
,
mUrlList
){
foreach
(
UBUrlWidget
*
url
,
mUrlList
){
links
<<
url
->
url
();
QStringList
list
=
url
->
url
().
split
(
";"
);
QString
formedlink
=
"<a href="
;
if
(
!
list
.
at
(
0
).
startsWith
(
"http://"
))
formedlink
+=
"http://"
;
formedlink
+=
list
.
at
(
0
)
+
">"
+
list
.
at
(
1
)
+
"</a>"
;
links
<<
formedlink
;
}
}
mpPreview
->
setLinks
(
links
);
mpPreview
->
setLinks
(
links
);
}
}
...
@@ -674,17 +679,37 @@ UBUrlWidget::UBUrlWidget(QWidget *parent, const char *name):QWidget(parent)
...
@@ -674,17 +679,37 @@ UBUrlWidget::UBUrlWidget(QWidget *parent, const char *name):QWidget(parent)
setAttribute
(
Qt
::
WA_StyledBackground
,
true
);
setAttribute
(
Qt
::
WA_StyledBackground
,
true
);
setStyleSheet
(
UBApplication
::
globalStyleSheet
());
setStyleSheet
(
UBApplication
::
globalStyleSheet
());
mpLayout
=
new
Q
H
BoxLayout
(
this
);
mpLayout
=
new
Q
V
BoxLayout
(
this
);
setLayout
(
mpLayout
);
setLayout
(
mpLayout
);
mpLabelLayout
=
new
QHBoxLayout
(
this
);
mpUrlLabel
=
new
QLabel
(
tr
(
"Url"
),
this
);
mpUrlLabel
=
new
QLabel
(
tr
(
"Url"
),
this
);
mpLayout
->
addWidget
(
mpUrlLabel
,
0
);
mpLa
belLa
yout
->
addWidget
(
mpUrlLabel
,
0
);
mpUrl
=
new
QLineEdit
(
this
);
mpUrl
=
new
QLineEdit
(
this
);
mpUrl
->
setObjectName
(
"DockPaletteWidgetLineEdit"
);
mpUrl
->
setObjectName
(
"DockPaletteWidgetLineEdit"
);
mpLayout
->
addWidget
(
mpUrl
,
1
);
mpLabelLayout
->
addWidget
(
mpUrl
,
1
);
mpTitleLayout
=
new
QHBoxLayout
(
this
);
mpTitleLabel
=
new
QLabel
(
tr
(
"Title"
),
this
);
mpTitleLayout
->
addWidget
(
mpTitleLabel
,
0
);
mpTitle
=
new
QLineEdit
(
this
);
mpTitle
->
setObjectName
(
"DockPaletteWidgetLineEdit"
);
mpTitleLayout
->
addWidget
(
mpTitle
,
1
);
mpLayout
->
addLayout
(
mpTitleLayout
);
mpLayout
->
addLayout
(
mpLabelLayout
);
}
}
UBUrlWidget
::~
UBUrlWidget
()
UBUrlWidget
::~
UBUrlWidget
()
{
{
if
(
NULL
!=
mpTitle
){
delete
mpTitle
;
mpTitle
=
NULL
;
}
if
(
NULL
!=
mpTitleLabel
){
delete
mpTitleLabel
;
mpTitleLabel
=
NULL
;
}
if
(
NULL
!=
mpUrlLabel
){
if
(
NULL
!=
mpUrlLabel
){
delete
mpUrlLabel
;
delete
mpUrlLabel
;
mpUrlLabel
=
NULL
;
mpUrlLabel
=
NULL
;
...
@@ -693,6 +718,14 @@ UBUrlWidget::~UBUrlWidget()
...
@@ -693,6 +718,14 @@ UBUrlWidget::~UBUrlWidget()
delete
mpUrl
;
delete
mpUrl
;
mpUrl
=
NULL
;
mpUrl
=
NULL
;
}
}
if
(
NULL
!=
mpTitleLayout
){
delete
mpTitleLayout
;
mpTitleLayout
=
NULL
;
}
if
(
NULL
!=
mpLabelLayout
){
delete
mpLabelLayout
;
mpLabelLayout
=
NULL
;
}
if
(
NULL
!=
mpLayout
){
if
(
NULL
!=
mpLayout
){
delete
mpLayout
;
delete
mpLayout
;
mpLayout
=
NULL
;
mpLayout
=
NULL
;
...
@@ -704,7 +737,7 @@ QString UBUrlWidget::url()
...
@@ -704,7 +737,7 @@ QString UBUrlWidget::url()
QString
str
;
QString
str
;
if
(
NULL
!=
mpUrl
){
if
(
NULL
!=
mpUrl
){
str
=
mpUrl
->
text
();
str
=
mpUrl
->
text
()
+
";"
+
mpTitle
->
text
()
;
}
}
return
str
;
return
str
;
...
@@ -712,8 +745,10 @@ QString UBUrlWidget::url()
...
@@ -712,8 +745,10 @@ QString UBUrlWidget::url()
void
UBUrlWidget
::
setUrl
(
const
QString
&
url
)
void
UBUrlWidget
::
setUrl
(
const
QString
&
url
)
{
{
QStringList
list
=
url
.
split
(
";"
);
if
(
NULL
!=
mpUrl
){
if
(
NULL
!=
mpUrl
){
mpUrl
->
setText
(
url
);
mpUrl
->
setText
(
list
.
at
(
0
));
mpTitle
->
setText
(
list
.
at
(
1
));
}
}
}
}
...
...
src/gui/UBTeacherBarWidget.h
View file @
6b1da4b6
...
@@ -107,9 +107,14 @@ public:
...
@@ -107,9 +107,14 @@ public:
void
setUrl
(
const
QString
&
url
);
void
setUrl
(
const
QString
&
url
);
private
:
private
:
QHBoxLayout
*
mpLayout
;
QVBoxLayout
*
mpLayout
;
QHBoxLayout
*
mpLabelLayout
;
QHBoxLayout
*
mpTitleLayout
;
QLabel
*
mpUrlLabel
;
QLabel
*
mpUrlLabel
;
QLineEdit
*
mpUrl
;
QLineEdit
*
mpUrl
;
QLabel
*
mpTitleLabel
;
QLineEdit
*
mpTitle
;
};
};
class
UBActionPreview
:
public
QWidget
class
UBActionPreview
:
public
QWidget
...
...
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