Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
otb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
273
Issues
273
List
Boards
Labels
Service Desk
Milestones
Merge Requests
8
Merge Requests
8
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Main Repositories
otb
Commits
8a50d511
Commit
8a50d511
authored
Jul 06, 2018
by
Victor Poughon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
REFAC: clean inline functions in WrapperQtWidgetView
parent
25cb7aeb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
38 additions
and
85 deletions
+38
-85
Modules/Wrappers/QtWidget/include/otbWrapperQtWidgetView.h
Modules/Wrappers/QtWidget/include/otbWrapperQtWidgetView.h
+7
-84
Modules/Wrappers/QtWidget/src/otbWrapperQtWidgetView.cxx
Modules/Wrappers/QtWidget/src/otbWrapperQtWidgetView.cxx
+31
-1
No files found.
Modules/Wrappers/QtWidget/include/otbWrapperQtWidgetView.h
View file @
8a50d511
...
...
@@ -63,22 +63,9 @@ public:
void
CreateGui
();
/** \brief Model Accessor */
inline
otb
::
Wrapper
::
QtWidgetModel
*
GetModel
()
{
return
m_Model
;
}
/**
* \return The OTB-application pointer of this view.
*/
//~ otb::Wrapper::Application::ConstPointer GetApplication() const
//~ {
//~ return otb::ConstCast< otb::Wrapper::Application >(
//~ m_Application
//~ );
//~ }
inline
bool
IsClosable
()
const
;
QtWidgetModel
*
GetModel
()
const
;
bool
IsClosable
()
const
;
public
slots
:
...
...
@@ -91,7 +78,7 @@ signals:
protected:
bool
IsRunning
();
bool
IsRunning
()
const
;
virtual
QWidget
*
CreateInputWidgets
();
...
...
@@ -122,7 +109,6 @@ private:
QWidget
*
CreateDoc
();
// Private attributes.
private:
...
...
@@ -136,24 +122,15 @@ private:
QTabWidget
*
m_TabWidget
;
bool
m_IsClosable
:
1
;
bool
m_IsRunning
;
private
slots
:
void
UpdateMessageAfterExecution
(
int
status
);
void
UpdateMessageAfterApplicationReady
(
bool
val
);
/**
*/
inline
void
OnProgressReportBegin
();
/**
*/
inline
void
OnProgressReportEnd
(
int
status
);
/**
*/
inline
void
SetClosable
(
bool
);
void
OnProgressReportBegin
();
void
OnProgressReportEnd
(
int
status
);
void
SetClosable
(
bool
);
};
...
...
@@ -161,58 +138,4 @@ private slots:
}
// end namespace 'otb'
/*****************************************************************************/
/* INLINE SECTION */
namespace
otb
{
namespace
Wrapper
{
/*****************************************************************************/
inline
bool
QtWidgetView
::
IsClosable
()
const
{
return
m_IsClosable
;
}
/*****************************************************************************/
inline
void
QtWidgetView
::
SetClosable
(
bool
enabled
)
{
m_IsClosable
=
enabled
;
setEnabled
(
true
);
if
(
m_QuitButton
!=
NULL
)
m_QuitButton
->
setEnabled
(
m_IsClosable
);
}
/*******************************************************************************/
inline
void
QtWidgetView
::
OnProgressReportBegin
()
{
SetClosable
(
false
);
}
/*******************************************************************************/
inline
void
QtWidgetView
::
OnProgressReportEnd
(
int
)
{
SetClosable
(
true
);
}
}
// end namespace 'Wrapper'
}
// end namespace 'otb'
#endif
Modules/Wrappers/QtWidget/src/otbWrapperQtWidgetView.cxx
View file @
8a50d511
...
...
@@ -285,11 +285,41 @@ void QtWidgetView::OnExceptionRaised( QString /*message*/)
m_TabWidget
->
setCurrentIndex
(
1
);
}
bool
QtWidgetView
::
IsRunning
()
bool
QtWidgetView
::
IsRunning
()
const
{
return
m_IsRunning
;
}
QtWidgetModel
*
QtWidgetView
::
GetModel
()
const
{
return
m_Model
;
}
bool
QtWidgetView
::
IsClosable
()
const
{
return
m_IsClosable
;
}
void
QtWidgetView
::
SetClosable
(
bool
enabled
)
{
m_IsClosable
=
enabled
;
setEnabled
(
true
);
if
(
m_QuitButton
!=
NULL
)
m_QuitButton
->
setEnabled
(
m_IsClosable
);
}
void
QtWidgetView
::
OnProgressReportBegin
()
{
SetClosable
(
false
);
}
void
QtWidgetView
::
OnProgressReportEnd
(
int
)
{
SetClosable
(
true
);
}
}
// end of namespace Wrapper
}
// end of namespace otb
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