Commit fda68e9b authored by Jan Möbius's avatar Jan Möbius

More const refs

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@13343 383ad7c9-94d9-4d36-a494-682f7c89f535
parent bb1f618e
...@@ -565,7 +565,7 @@ const std::string pickMode () { ...@@ -565,7 +565,7 @@ const std::string pickMode () {
return viewerProperties().pickMode(); return viewerProperties().pickMode();
} }
void pickMode ( const std::string _mode) { void pickMode ( const std::string& _mode) {
// switch to default marker // switch to default marker
setViewObjectMarker (defaultViewObjectMarker ()); setViewObjectMarker (defaultViewObjectMarker ());
viewerProperties().pickMode(_mode); viewerProperties().pickMode(_mode);
......
...@@ -351,7 +351,7 @@ const std::string pickMode (); ...@@ -351,7 +351,7 @@ const std::string pickMode ();
/// Set the current Picking mode for all examiner widgets /// Set the current Picking mode for all examiner widgets
DLLEXPORT DLLEXPORT
void pickMode ( const std::string _mode); void pickMode ( const std::string& _mode);
/// Returns a QImage of the current View /// Returns a QImage of the current View
DLLEXPORT DLLEXPORT
......
...@@ -798,7 +798,7 @@ Core::slotWheelEvent( QWheelEvent * _event, const std::string & _mode) ...@@ -798,7 +798,7 @@ Core::slotWheelEvent( QWheelEvent * _event, const std::string & _mode)
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void void
Core::slotAddPickMode( const std::string _mode ) { Core::slotAddPickMode( const std::string& _mode ) {
if ( OpenFlipper::Options::gui() ) if ( OpenFlipper::Options::gui() )
coreWidget_->addPickMode(_mode); coreWidget_->addPickMode(_mode);
...@@ -807,7 +807,7 @@ Core::slotAddPickMode( const std::string _mode ) { ...@@ -807,7 +807,7 @@ Core::slotAddPickMode( const std::string _mode ) {
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void void
Core::slotAddHiddenPickMode( const std::string _mode ) { Core::slotAddHiddenPickMode( const std::string& _mode ) {
if ( OpenFlipper::Options::gui() ) if ( OpenFlipper::Options::gui() )
coreWidget_->addPickMode(_mode,false,1000,false); coreWidget_->addPickMode(_mode,false,1000,false);
......
...@@ -409,10 +409,10 @@ signals: ...@@ -409,10 +409,10 @@ signals:
void slotObjectSelectionChanged( int _id); void slotObjectSelectionChanged( int _id);
/// Add a new picking mode to the examiner_widget_ /// Add a new picking mode to the examiner_widget_
void slotAddPickMode( const std::string _mode ); void slotAddPickMode( const std::string& _mode );
/// Add a new and invisible picking mode to the examiner_widget_ /// Add a new and invisible picking mode to the examiner_widget_
void slotAddHiddenPickMode( const std::string _mode ); void slotAddHiddenPickMode( const std::string& _mode );
/// Called by a plugin if it creates a texture /// Called by a plugin if it creates a texture
void slotAddTexture( QString _textureName , QString _filename , uint _dimension , int _id ); void slotAddTexture( QString _textureName , QString _filename , uint _dimension , int _id );
......
...@@ -239,7 +239,6 @@ void Core::readApplicationOptions(INIFile& _ini) { ...@@ -239,7 +239,6 @@ void Core::readApplicationOptions(INIFile& _ini) {
// Load the viewer settings // Load the viewer settings
//============================================================================ //============================================================================
std::vector< QString > draw_modes; std::vector< QString > draw_modes;
int mode;
for (int i=0; i < 4/*PluginFunctions::viewers()*/; i++ ){ for (int i=0; i < 4/*PluginFunctions::viewers()*/; i++ ){
......
...@@ -512,7 +512,7 @@ namespace Viewer { ...@@ -512,7 +512,7 @@ namespace Viewer {
void drawModeChanged(int _viewerId ); void drawModeChanged(int _viewerId );
void getPickMode(std::string& _mode ); void getPickMode(std::string& _mode );
void setPickMode(const std::string _mode ); void setPickMode(const std::string& _mode );
void getActionMode(Viewer::ActionMode& _am); void getActionMode(Viewer::ActionMode& _am);
void setActionMode(const Viewer::ActionMode _am); void setActionMode(const Viewer::ActionMode _am);
......
...@@ -1361,7 +1361,7 @@ public: ...@@ -1361,7 +1361,7 @@ public:
/** Switch to given picking mode /** Switch to given picking mode
* @param _name Name of the picking mode * @param _name Name of the picking mode
*/ */
void setPickMode(const std::string _name); void setPickMode(const std::string& _name);
void getPickMode(std::string& _name); void getPickMode(std::string& _name);
...@@ -1395,7 +1395,7 @@ public: ...@@ -1395,7 +1395,7 @@ public:
* @param _mode Identifier of Picking mode * @param _mode Identifier of Picking mode
* @param _toolbar the toolbar * @param _toolbar the toolbar
*/ */
void setPickModeToolbar( const std::string _mode , QToolBar * _toolbar ); void setPickModeToolbar( const std::string& _mode , QToolBar * _toolbar );
/** \brief Removes the additional toolbar of the given PickMode /** \brief Removes the additional toolbar of the given PickMode
* *
...@@ -1403,7 +1403,7 @@ public: ...@@ -1403,7 +1403,7 @@ public:
* *
* @param _mode Identifier of Picking mode * @param _mode Identifier of Picking mode
*/ */
void removePickModeToolbar( const std::string _mode ); void removePickModeToolbar( const std::string& _mode );
void actionPickMenu( QAction * _action ); void actionPickMenu( QAction * _action );
......
...@@ -156,7 +156,7 @@ void CoreWidget::getActionMode(Viewer::ActionMode& _am){ ...@@ -156,7 +156,7 @@ void CoreWidget::getActionMode(Viewer::ActionMode& _am){
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void CoreWidget::setPickMode(const std::string _mode){ void CoreWidget::setPickMode(const std::string& _mode){
for (unsigned int i=0; i<pick_modes_.size(); ++i) for (unsigned int i=0; i<pick_modes_.size(); ++i)
{ {
...@@ -434,7 +434,7 @@ void CoreWidget::setPickModeMouseTracking(const std::string& _name, bool _mouseT ...@@ -434,7 +434,7 @@ void CoreWidget::setPickModeMouseTracking(const std::string& _name, bool _mouseT
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void CoreWidget::setPickModeToolbar( const std::string _mode , QToolBar * _toolbar ) void CoreWidget::setPickModeToolbar( const std::string& _mode , QToolBar * _toolbar )
{ {
// Get the pickmode that belongs to the given name // Get the pickmode that belongs to the given name
for (uint i=0; i < pick_modes_.size(); i++) for (uint i=0; i < pick_modes_.size(); i++)
...@@ -453,7 +453,7 @@ void CoreWidget::setPickModeToolbar( const std::string _mode , QToolBar * _toolb ...@@ -453,7 +453,7 @@ void CoreWidget::setPickModeToolbar( const std::string _mode , QToolBar * _toolb
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void CoreWidget::removePickModeToolbar( const std::string _mode ) void CoreWidget::removePickModeToolbar( const std::string& _mode )
{ {
for (uint i=0; i < pick_modes_.size(); i++) for (uint i=0; i < pick_modes_.size(); i++)
if ( pick_modes_[i].name() == _mode ){ if ( pick_modes_[i].name() == _mode ){
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment