Kaydet (Commit) 5934fb94 authored tarafından Kurt Zenker's avatar Kurt Zenker

INTEGRATION: CWS titles02 (1.192.8); FILE MERGED

2008/02/12 13:25:00 as 1.192.8.3: RESYNC: (1.192-1.193); FILE MERGED
2007/12/17 15:29:55 oj 1.192.8.2: #i45617# title feature
2007/12/10 11:38:44 oj 1.192.8.1: #i45909# #i45617# #i71469# change title handling
üst bf7b7c9c
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: unodatbr.cxx,v $ * $RCSfile: unodatbr.cxx,v $
* *
* $Revision: 1.196 $ * $Revision: 1.197 $
* *
* last change: $Author: kz $ $Date: 2008-03-06 18:15:05 $ * last change: $Author: kz $ $Date: 2008-04-04 14:00:44 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -2401,7 +2401,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnSelectEntry, SvLBoxEntry*, _pEntry) ...@@ -2401,7 +2401,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnSelectEntry, SvLBoxEntry*, _pEntry)
String sDataSourceName( getDataSourceAcessor( pConnection ) ); String sDataSourceName( getDataSourceAcessor( pConnection ) );
if ( implLoadAnything( sDataSourceName, aName, nCommandType, sal_True, pConData->xConnection ) ) if ( implLoadAnything( sDataSourceName, aName, nCommandType, sal_True, pConData->xConnection ) )
// set the title of the beamer // set the title of the beamer
updateTitle(); ;/*updateTitle();*/
else else
{ // clean up { // clean up
criticalFail(); criticalFail();
...@@ -2837,9 +2837,6 @@ void SbaTableQueryBrowser::unloadAndCleanup( sal_Bool _bDisposeConnection ) ...@@ -2837,9 +2837,6 @@ void SbaTableQueryBrowser::unloadAndCleanup( sal_Bool _bDisposeConnection )
{ {
OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: could not reset the form"); OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: could not reset the form");
} }
// set a default title
setDefaultTitle();
} }
// ------------------------------------------------------------------------- // -------------------------------------------------------------------------
...@@ -3049,11 +3046,6 @@ void SbaTableQueryBrowser::impl_initialize() ...@@ -3049,11 +3046,6 @@ void SbaTableQueryBrowser::impl_initialize()
OSL_ENSURE(sal_False, "SbaTableQueryBrowser::impl_initialize: could not set the update related names!"); OSL_ENSURE(sal_False, "SbaTableQueryBrowser::impl_initialize: could not set the update related names!");
} }
} }
else
{
// set a default title
setDefaultTitle();
}
InvalidateAll(); InvalidateAll();
} }
...@@ -3439,12 +3431,6 @@ sal_Bool SbaTableQueryBrowser::requestContextMenu( const CommandEvent& _rEvent ) ...@@ -3439,12 +3431,6 @@ sal_Bool SbaTableQueryBrowser::requestContextMenu( const CommandEvent& _rEvent )
return sal_True; // handled return sal_True; // handled
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
void SbaTableQueryBrowser::setDefaultTitle()
{
::rtl::OUString sTitle = String(ModuleRes(STR_DSBROWSER_TITLE));
setTitle(sTitle);
}
// -----------------------------------------------------------------------------
sal_Bool SbaTableQueryBrowser::implGetQuerySignature( ::rtl::OUString& _rCommand, sal_Bool& _bEscapeProcessing ) sal_Bool SbaTableQueryBrowser::implGetQuerySignature( ::rtl::OUString& _rCommand, sal_Bool& _bEscapeProcessing )
{ {
_rCommand = ::rtl::OUString(); _rCommand = ::rtl::OUString();
...@@ -3551,25 +3537,28 @@ void SbaTableQueryBrowser::loadMenu(const Reference< XFrame >& _xFrame) ...@@ -3551,25 +3537,28 @@ void SbaTableQueryBrowser::loadMenu(const Reference< XFrame >& _xFrame)
} }
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
void SbaTableQueryBrowser::updateTitle() ::rtl::OUString SbaTableQueryBrowser::getPrivateTitle() const
{ {
::rtl::OUString sTitle;
if ( m_pCurrentlyDisplayed ) if ( m_pCurrentlyDisplayed )
{ {
SvLBoxEntry* pContainer = m_pTreeModel->GetParent(m_pCurrentlyDisplayed); SvLBoxEntry* pContainer = m_pTreeModel->GetParent(m_pCurrentlyDisplayed);
// get the entry for the datasource // get the entry for the datasource
SvLBoxEntry* pConnection = m_pTreeModel->GetParent(pContainer); SvLBoxEntry* pConnection = m_pTreeModel->GetParent(pContainer);
::rtl::OUString sName = m_pTreeView->getListBox()->GetEntryText(m_pCurrentlyDisplayed); ::rtl::OUString sName = m_pTreeView->getListBox()->GetEntryText(m_pCurrentlyDisplayed);
::rtl::OUString sTitle = GetEntryText( pConnection ); sTitle = GetEntryText( pConnection );
INetURLObject aURL(sTitle); INetURLObject aURL(sTitle);
if ( aURL.GetProtocol() != INET_PROT_NOT_VALID ) if ( aURL.GetProtocol() != INET_PROT_NOT_VALID )
sTitle = aURL.getBase(INetURLObject::LAST_SEGMENT,true,INetURLObject::DECODE_WITH_CHARSET); sTitle = aURL.getBase(INetURLObject::LAST_SEGMENT,true,INetURLObject::DECODE_WITH_CHARSET);
if(sName.getLength()) if ( sName.getLength() )
{ {
sTitle += ::rtl::OUString::createFromAscii(": "); sName += ::rtl::OUString::createFromAscii(" - ");
sTitle += sName; sName += sTitle;
sTitle = sName;
} }
setTitle(sTitle);
} }
return sTitle;
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
sal_Bool SbaTableQueryBrowser::preReloadForm() sal_Bool SbaTableQueryBrowser::preReloadForm()
...@@ -3604,7 +3593,7 @@ void SbaTableQueryBrowser::postReloadForm() ...@@ -3604,7 +3593,7 @@ void SbaTableQueryBrowser::postReloadForm()
{ {
InitializeGridModel(getFormComponent()); InitializeGridModel(getFormComponent());
LoadFinished(sal_True); LoadFinished(sal_True);
updateTitle(); //updateTitle();
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
......
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