#include <SUIT_ResourceMgr.h>
#include <QtxMRUAction.h>
+#include <QtxTreeView.h>
// temporary commented
//#include <OB_ListItem.h>
updateSavePointDataObjects( study );
}
+/*!Called on New study operation*/
+void SalomeApp_Application::onStudyCreated( SUIT_Study* study )
+{
+ LightApp_Application::onStudyCreated( study );
+
+ objectBrowserColumnsVisibility();
+}
+
/*!Called on Save study operation*/
void SalomeApp_Application::onStudySaved( SUIT_Study* study )
{
{
LightApp_Application::onStudyOpened( study );
+ objectBrowserColumnsVisibility();
+
// temporary commented
/*if ( objectBrowser() ) {
updateSavePointDataObjects( dynamic_cast<SalomeApp_Study*>( study ) );
updateCommandsStatus();
return res;
}
+
+/*! Show/hide object browser colums according to preferences */
+void SalomeApp_Application::objectBrowserColumnsVisibility()
+{
+ if ( objectBrowser() )
+ for ( int i = SalomeApp_DataObject::EntryIdx; i <= SalomeApp_DataObject::RefEntryIdx; i++ )
+ objectBrowser()->treeView()->setColumnHidden( i,
+ !(resourceMgr()->booleanValue( "ObjectBrowser",
+ QString().sprintf( "visibility_column_%d", i-1 ),
+ true )) );
+}
void onSaveGUIState();// called from VISU
protected slots:
+ void onStudyCreated( SUIT_Study* );
void onStudySaved( SUIT_Study* );
void onStudyOpened( SUIT_Study* );
void onDesktopMessage( const QString& );
virtual QMap<int, QString> activateModuleActions() const;
virtual void moduleActionSelected( const int );
+ void objectBrowserColumnsVisibility();
+
private slots:
void onDeleteInvalidReferences();
void onDblClick( QListViewItem* );
<parameter name="auto_hide_search_tool" value="true" />
<parameter name="auto_size" value="false" />
<parameter name="auto_size_first" value="true" />
- <parameter name="visibility_column_0" value="true" />
- <parameter name="visibility_column_1" value="false" />
+ <parameter name="visibility_column_0" value="false" />
+ <parameter name="visibility_column_1" value="true" />
<parameter name="visibility_column_2" value="false" />
<parameter name="visibility_column_3" value="false" />
</section>
msgstr "Object"
msgid "SalomeApp_Application::OBJ_BROWSER_COLUMN_0"
-msgstr "Value"
+msgstr "Entry"
msgid "SalomeApp_Application::OBJ_BROWSER_COLUMN_1"
-msgstr "Entry"
+msgstr "Value"
msgid "SalomeApp_Application::OBJ_BROWSER_COLUMN_2"
msgstr "IOR"
</message>
<message>
<source>OBJ_BROWSER_COLUMN_0</source>
- <translation>Value</translation>
+ <translation>Entry</translation>
</message>
<message>
<source>OBJ_BROWSER_COLUMN_1</source>
- <translation>Entry</translation>
+ <translation>Value</translation>
</message>
<message>
<source>OBJ_BROWSER_COLUMN_2</source>