User: kz      
Date: 2008-06-25 12:37:14+0000
Modified:
   dba/dbaccess/source/ui/app/AppDetailView.cxx

Log:
 INTEGRATION: CWS dba30d (1.28.30); FILE MERGED
 2008/06/10 13:56:39 fs 1.28.30.5: #i10000#
 2008/06/10 11:04:41 fs 1.28.30.4: +describeCurrentSelectionForType
 2008/06/09 13:45:17 fs 1.28.30.3: names
 2008/06/01 21:02:32 fs 1.28.30.2: #i80943# more preparations for context menu 
interception, including some re-factoring
 2008/05/29 11:32:27 fs 1.28.30.1: during #i80943#: refactoring: IController 
now passed around as reference, not as pointer

File Changes:

Directory: /dba/dbaccess/source/ui/app/
=======================================

File [changed]: AppDetailView.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/app/AppDetailView.cxx?r1=1.28&r2=1.29
Delta lines:  +24 -14
---------------------
--- AppDetailView.cxx   2008-04-10 13:57:50+0000        1.28
+++ AppDetailView.cxx   2008-06-25 12:37:11+0000        1.29
@@ -45,9 +45,6 @@
 #ifndef DBAUI_APPVIEW_HXX
 #include "AppView.hxx"
 #endif
-#ifndef DBAUI_IAPPELEMENTNOTIFICATION_HXX
-#include "IAppElementNotification.hxx"
-#endif
 #ifndef _COM_SUN_STAR_UI_XUICONFIGURATIONMANAGER_HPP_
 #include <com/sun/star/ui/XUIConfigurationManager.hpp>
 #endif
@@ -104,6 +101,7 @@
 #endif
 #include <algorithm>
 #include "dbtreelistbox.hxx"
+#include "IApplicationController.hxx"
 
 using namespace ::dbaui;
 using namespace ::com::sun::star::uno;
@@ -114,6 +112,9 @@
 using namespace ::com::sun::star::graphic;
 using namespace ::com::sun::star::ui;
 using namespace ::com::sun::star::container;
+using namespace ::com::sun::star::beans;
+using ::com::sun::star::util::URL;
+using ::com::sun::star::sdb::application::NamedDatabaseObject;
 
 #define SPACEBETWEENENTRIES            4
 
@@ -363,7 +364,9 @@
 void OCreationList::onSelected( SvLBoxEntry* _pEntry ) const
 {
     DBG_ASSERT( _pEntry, "OCreationList::onSelected: invalid entry!" );
-    m_rTaskWindow.getDetailView()->onCreationClick( reinterpret_cast< 
TaskEntry* >( _pEntry->GetUserData() )->sUNOCommand );
+       URL aCommand;
+       aCommand.Complete = reinterpret_cast< TaskEntry* >( 
_pEntry->GetUserData() )->sUNOCommand;
+    
m_rTaskWindow.getDetailView()->getBorderWin().getView()->getAppController().executeChecked(
 aCommand, Sequence< PropertyValue >() );
 }
 // 
-----------------------------------------------------------------------------
 void OCreationList::KeyInput( const KeyEvent& rKEvt )
@@ -609,7 +612,7 @@
 
        OTasksWindow* pTasks = new OTasksWindow(&m_aTasks,this);
        pTasks->Show();
-       
pTasks->Disable(m_rBorderWin.getView()->getCommandController()->isDataSourceReadOnly());
+       
pTasks->Disable(m_rBorderWin.getView()->getCommandController().isDataSourceReadOnly());
        m_aTasks.setChildWindow(pTasks);
        m_aTasks.SetUniqueId(UID_APP_TASKS_VIEW);
        m_aTasks.Show();
@@ -727,7 +730,7 @@
     OSL_ENSURE( !rData.aTasks.empty(), 
"OApplicationDetailView::impl_createPage: no tasks at all!?" );
     bool bEnabled = rData.aTasks.empty()
                 ?   false
-                :   
getBorderWin().getView()->getCommandController()->isCommandEnabled( 
rData.aTasks[0].sUNOCommand );
+                :   
getBorderWin().getView()->getCommandController().isCommandEnabled( 
rData.aTasks[0].sUNOCommand );
        getTasksWindow().Enable( bEnabled );
        m_aContainer.setTitle( rData.nTitleId );
 
@@ -745,7 +748,7 @@
 const TaskPaneData& OApplicationDetailView::impl_getTaskPaneData( ElementType 
_eType )
 {
     if ( m_aTaskPaneData.empty() )
-        m_aTaskPaneData.resize( E_ELEMENT_TYPE_COUNT );
+        m_aTaskPaneData.resize( ELEMENT_COUNT );
     OSL_ENSURE( ( _eType >= 0 ) && ( _eType < E_ELEMENT_TYPE_COUNT ), 
"OApplicationDetailView::impl_getTaskPaneData: illegal element type!" );
     TaskPaneData& rData = m_aTaskPaneData[ _eType ];
 
@@ -802,7 +805,7 @@
         )
     {
         if  (   pTask->bHideWhenDisabled
-            &&  
!getBorderWin().getView()->getCommandController()->isCommandEnabled( 
pTask->sUNOCommand )
+            &&  
!getBorderWin().getView()->getCommandController().isCommandEnabled( 
pTask->sUNOCommand )
             )
             pTask = rList.erase( pTask );
         else
@@ -891,6 +894,7 @@
        DBG_CHKTHIS(OApplicationDetailView,NULL);
        return m_pControlHelper->getElementCount();
 }
+
 // 
-----------------------------------------------------------------------------
 void OApplicationDetailView::getSelectionElementNames( ::std::vector< 
::rtl::OUString>& _rNames ) const
 {
@@ -898,6 +902,18 @@
        m_pControlHelper->getSelectionElementNames( _rNames );
 }
 // 
-----------------------------------------------------------------------------
+void OApplicationDetailView::describeCurrentSelectionForControl( const 
Control& _rControl, Sequence< NamedDatabaseObject >& _out_rSelectedObjects )
+{
+       DBG_CHKTHIS(OApplicationDetailView,NULL);
+       m_pControlHelper->describeCurrentSelectionForControl( _rControl, 
_out_rSelectedObjects );
+}
+// 
-----------------------------------------------------------------------------
+void OApplicationDetailView::describeCurrentSelectionForType( const 
ElementType _eType, Sequence< NamedDatabaseObject >& _out_rSelectedObjects )
+{
+       DBG_CHKTHIS(OApplicationDetailView,NULL);
+       m_pControlHelper->describeCurrentSelectionForType( _eType, 
_out_rSelectedObjects );
+}
+// 
-----------------------------------------------------------------------------
 void OApplicationDetailView::selectElements(const Sequence< ::rtl::OUString>& 
_aNames)
 {
     DBG_CHKTHIS(OApplicationDetailView,NULL);
@@ -929,12 +945,6 @@
        m_pControlHelper->paste(); 
 }
 // 
-----------------------------------------------------------------------------
-void OApplicationDetailView::onCreationClick( const ::rtl::OUString& _sCommand)
-{
-       DBG_CHKTHIS(OApplicationDetailView,NULL);
-       
getBorderWin().getView()->getElementNotification()->onCreationClick(_sCommand);
-}
-// 
-----------------------------------------------------------------------------
 SvLBoxEntry*  OApplicationDetailView::elementAdded(ElementType _eType,const 
::rtl::OUString& _rName, const Any& _rObject )
 {
        DBG_CHKTHIS(OApplicationDetailView,NULL);




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to