|
|
@ -24,7 +24,6 @@ UBTeacherBarWidget::UBTeacherBarWidget(QWidget *parent, const char *name):UBDock |
|
|
|
, mpTitleLabel(NULL) |
|
|
|
, mpTitleLabel(NULL) |
|
|
|
, mpDurationLabel(NULL) |
|
|
|
, mpDurationLabel(NULL) |
|
|
|
, mpTitle(NULL) |
|
|
|
, mpTitle(NULL) |
|
|
|
, mpAction1(NULL) |
|
|
|
|
|
|
|
, mpMediaLabel(NULL) |
|
|
|
, mpMediaLabel(NULL) |
|
|
|
, mpDropMediaZone(NULL) |
|
|
|
, mpDropMediaZone(NULL) |
|
|
|
, mpContainer(NULL) |
|
|
|
, mpContainer(NULL) |
|
|
@ -185,10 +184,6 @@ UBTeacherBarWidget::~UBTeacherBarWidget() |
|
|
|
delete mpActionLayout; |
|
|
|
delete mpActionLayout; |
|
|
|
mpActionLayout = NULL; |
|
|
|
mpActionLayout = NULL; |
|
|
|
} |
|
|
|
} |
|
|
|
if(NULL != mpAction1){ |
|
|
|
|
|
|
|
delete mpAction1; |
|
|
|
|
|
|
|
mpAction1 = NULL; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
if(NULL != mpActionLabel){ |
|
|
|
if(NULL != mpActionLabel){ |
|
|
|
delete mpActionLabel; |
|
|
|
delete mpActionLabel; |
|
|
|
mpActionLabel = NULL; |
|
|
|
mpActionLabel = NULL; |
|
|
@ -297,6 +292,7 @@ void UBTeacherBarWidget::saveContent() |
|
|
|
|
|
|
|
|
|
|
|
void UBTeacherBarWidget::loadContent() |
|
|
|
void UBTeacherBarWidget::loadContent() |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
clearWidgetLists(); |
|
|
|
sTeacherBarInfos nextInfos = UBPersistenceManager::persistenceManager()->getTeacherBarInfos(UBApplication::boardController->activeDocument(), UBApplication::boardController->activeSceneIndex()); |
|
|
|
sTeacherBarInfos nextInfos = UBPersistenceManager::persistenceManager()->getTeacherBarInfos(UBApplication::boardController->activeDocument(), UBApplication::boardController->activeSceneIndex()); |
|
|
|
// Title
|
|
|
|
// Title
|
|
|
|
mpTitle->setText(nextInfos.title); |
|
|
|
mpTitle->setText(nextInfos.title); |
|
|
@ -360,6 +356,23 @@ void UBTeacherBarWidget::onLinkButton() |
|
|
|
mpLinks->addWidget(pUrl); |
|
|
|
mpLinks->addWidget(pUrl); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void UBTeacherBarWidget::clearWidgetLists() |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
if(NULL != mpActions){ |
|
|
|
|
|
|
|
for(int i=0; i<mActionList.size(); i++){ |
|
|
|
|
|
|
|
mpActions->removeWidget(mActionList.at(i)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
mActionList.clear(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(NULL != mpLinks){ |
|
|
|
|
|
|
|
for(int i=0; i<mUrlList.size(); i++){ |
|
|
|
|
|
|
|
mpLinks->removeWidget(mUrlList.at(i)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
mUrlList.clear(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// ---------------------------------------------------------------------------------------------
|
|
|
|
// ---------------------------------------------------------------------------------------------
|
|
|
|
UBTeacherStudentAction::UBTeacherStudentAction(QWidget *parent, const char *name):QWidget(parent) |
|
|
|
UBTeacherStudentAction::UBTeacherStudentAction(QWidget *parent, const char *name):QWidget(parent) |
|
|
|
, mpText(NULL) |
|
|
|
, mpText(NULL) |
|
|
|