summaryrefslogtreecommitdiff
path: root/dbaccess/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-04-25 15:43:34 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-04-25 20:50:41 +0100
commitfea8976c0152632919587dd4e3225d6283e6691f (patch)
tree1f8417da7d6c27be2bb027ef792b62146837d029 /dbaccess/source
parentf08faa70ccaa3bbf335b7b2ddff02a9f37efe125 (diff)
remove dbaccess bitmaps from .src files
Change-Id: I85e0d4bce7c2d1da2cc78c00e15e485152039c3e
Diffstat (limited to 'dbaccess/source')
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.cxx26
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.hxx4
-rw-r--r--dbaccess/source/ui/app/AppIconControl.cxx7
-rw-r--r--dbaccess/source/ui/dlg/CollectionView.cxx5
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.cxx3
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.src5
-rw-r--r--dbaccess/source/ui/dlg/sqlmessage.cxx15
-rw-r--r--dbaccess/source/ui/dlg/sqlmessage.src15
-rw-r--r--dbaccess/source/ui/imagelists/dbimagelists.src119
-rw-r--r--dbaccess/source/ui/inc/dbu_misc.hrc2
-rw-r--r--dbaccess/source/ui/inc/dbu_resource.hrc27
-rw-r--r--dbaccess/source/ui/inc/imageprovider.hxx4
-rw-r--r--dbaccess/source/ui/misc/WNameMatch.cxx11
-rw-r--r--dbaccess/source/ui/misc/WTypeSelect.cxx3
-rw-r--r--dbaccess/source/ui/misc/WizardPages.src10
-rw-r--r--dbaccess/source/ui/misc/imageprovider.cxx49
-rw-r--r--dbaccess/source/ui/querydesign/TableWindow.cxx3
-rw-r--r--dbaccess/source/ui/querydesign/query.src5
18 files changed, 68 insertions, 245 deletions
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index 950fbe17ac46..7897e6692227 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -583,10 +583,9 @@ void OAppDetailPageHelper::createTablesPage(const Reference< XConnection>& _xCon
setDetailPage(m_pLists[E_TABLE]);
}
-void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rImageId)
+OUString OAppDetailPageHelper::getElementIcons(ElementType _eType)
{
ImageProvider aImageProvider;
- _rImageId = 0;
sal_Int32 nDatabaseObjectType( 0 );
switch(_eType )
@@ -596,16 +595,16 @@ void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rIm
case E_QUERY: nDatabaseObjectType = DatabaseObject::QUERY; break;
default:
OSL_FAIL( "OAppDetailPageHelper::GetElementIcons: invalid element type!" );
- return;
+ return OUString();
}
- _rImageId = ImageProvider::getDefaultImageResourceID( nDatabaseObjectType );
+
+ return ImageProvider::getDefaultImageResourceID(nDatabaseObjectType);
}
void OAppDetailPageHelper::createPage(ElementType _eType,const Reference< XNameAccess >& _xContainer)
{
OSL_ENSURE(E_TABLE != _eType,"E_TABLE isn't allowed.");
- sal_uInt16 nImageId = 0;
OString sHelpId;
ImageProvider aImageProvider;
Image aFolderImage;
@@ -626,7 +625,7 @@ void OAppDetailPageHelper::createPage(ElementType _eType,const Reference< XNameA
default:
OSL_FAIL("Illegal call!");
}
- getElementIcons( _eType, nImageId );
+ OUString sImageId = getElementIcons(_eType);
if ( !m_pLists[_eType] )
{
@@ -637,7 +636,7 @@ void OAppDetailPageHelper::createPage(ElementType _eType,const Reference< XNameA
{
if ( !m_pLists[_eType]->GetEntryCount() && _xContainer.is() )
{
- fillNames( _xContainer, _eType, nImageId, nullptr );
+ fillNames( _xContainer, _eType, sImageId, nullptr );
m_pLists[_eType]->SelectAll(false);
}
@@ -682,7 +681,7 @@ namespace
}
void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContainer, const ElementType _eType,
- const sal_uInt16 _nImageId, SvTreeListEntry* _pParent )
+ const OUString& rImageId, SvTreeListEntry* _pParent )
{
OSL_ENSURE(_xContainer.is(),"Data source is NULL! -> GPF");
OSL_ENSURE( ( _eType >= E_TABLE ) && ( _eType < E_ELEMENT_TYPE_COUNT ), "OAppDetailPageHelper::fillNames: invalid type!" );
@@ -707,13 +706,13 @@ void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContaine
{
pEntry = pList->InsertEntry( *pIter, _pParent, false, TREELIST_APPEND, reinterpret_cast< void* >( nFolderIndicator ) );
getBorderWin().getView()->getAppController().containerFound( Reference< XContainer >( xSubElements, UNO_QUERY ) );
- fillNames( xSubElements, _eType, _nImageId, pEntry );
+ fillNames( xSubElements, _eType, rImageId, pEntry );
}
else
{
pEntry = pList->InsertEntry( *pIter, _pParent );
- Image aImage{BitmapEx(ModuleRes(_nImageId))};
+ Image aImage{BitmapEx(rImageId)};
pList->SetExpandedEntryBmp(pEntry, aImage);
pList->SetCollapsedEntryBmp(pEntry, aImage);
}
@@ -829,20 +828,19 @@ SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const OUS
}
}
- sal_uInt16 nImageId = 0;
- getElementIcons( _eType, nImageId );
+ OUString sImageId = getElementIcons(_eType);
Reference<XNameAccess> xContainer(_rObject,UNO_QUERY);
if ( xContainer.is() )
{
const sal_Int32 nFolderIndicator = lcl_getFolderIndicatorForType( _eType );
pRet = pTreeView->InsertEntry( _rName, pEntry, false, TREELIST_APPEND, reinterpret_cast< void* >( nFolderIndicator ) );
- fillNames( xContainer, _eType, nImageId, pRet );
+ fillNames( xContainer, _eType, sImageId, pRet );
}
else
{
pRet = pTreeView->InsertEntry( _rName, pEntry );
- Image aImage{BitmapEx(ModuleRes(nImageId))};
+ Image aImage{BitmapEx(sImageId)};
pTreeView->SetExpandedEntryBmp( pRet, aImage );
pTreeView->SetCollapsedEntryBmp( pRet, aImage );
}
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.hxx b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
index 0041f6c636d2..b6c05d50ec7f 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.hxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
@@ -105,7 +105,7 @@ namespace dbaui
/** retrieves the resource ids of the images representing elements of the given type
*/
- static void getElementIcons( ElementType _eType, sal_uInt16& _rImageId);
+ static OUString getElementIcons(ElementType _eType);
/** fills the names in the listbox
@param _xContainer
@@ -119,7 +119,7 @@ namespace dbaui
*/
void fillNames( const css::uno::Reference< css::container::XNameAccess >& _xContainer,
const ElementType _eType,
- const sal_uInt16 _nImageId,
+ const OUString& rImageId,
SvTreeListEntry* _pParent );
/** sets the detail page
diff --git a/dbaccess/source/ui/app/AppIconControl.cxx b/dbaccess/source/ui/app/AppIconControl.cxx
index 4ac9205b108f..85c12fa3ddb8 100644
--- a/dbaccess/source/ui/app/AppIconControl.cxx
+++ b/dbaccess/source/ui/app/AppIconControl.cxx
@@ -22,6 +22,7 @@
#include "dbaccess_helpid.hrc"
#include "moduledbu.hxx"
#include "dbu_app.hrc"
+#include "bitmaps.hlst"
#include <vcl/image.hxx>
#include "callbacks.hxx"
#include "AppElementType.hxx"
@@ -38,9 +39,9 @@ OApplicationIconControl::OApplicationIconControl(vcl::Window* _pParent)
const struct CategoryDescriptor
{
- sal_uInt16 nLabelResId;
+ sal_uInt16 nLabelResId;
ElementType eType;
- sal_uInt16 nImageResId;
+ const char* aImageResId;
} aCategories[] = {
{ RID_STR_TABLES_CONTAINER, E_TABLE, BMP_TABLEFOLDER_TREE_L },
{ RID_STR_QUERIES_CONTAINER, E_QUERY, BMP_QUERYFOLDER_TREE_L },
@@ -51,7 +52,7 @@ OApplicationIconControl::OApplicationIconControl(vcl::Window* _pParent)
{
SvxIconChoiceCtrlEntry* pEntry = InsertEntry(
OUString( ModuleRes( aCategorie.nLabelResId ) ) ,
- Image(BitmapEx(ModuleRes(aCategorie.nImageResId))));
+ Image(BitmapEx(OUString::createFromAscii(aCategorie.aImageResId))));
if ( pEntry )
pEntry->SetUserData( new ElementType( aCategorie.eType ) );
}
diff --git a/dbaccess/source/ui/dlg/CollectionView.cxx b/dbaccess/source/ui/dlg/CollectionView.cxx
index 8899c2646bc1..5b59928037ab 100644
--- a/dbaccess/source/ui/dlg/CollectionView.cxx
+++ b/dbaccess/source/ui/dlg/CollectionView.cxx
@@ -32,6 +32,7 @@
#include <com/sun/star/beans/PropertyValue.hpp>
#include <vcl/msgbox.hxx>
#include "dbustrings.hrc"
+#include "bitmaps.hlst"
#include "UITools.hxx"
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
#include <com/sun/star/ucb/InteractiveAugmentedIOException.hpp>
@@ -80,8 +81,8 @@ OCollectionView::OCollectionView( vcl::Window * pParent
m_pName->GrabFocus();
m_pNewFolder->SetStyle( m_pNewFolder->GetStyle() | WB_NOPOINTERFOCUS );
- m_pUp->SetModeImage(Image(BitmapEx(ModuleRes(BMP_NAVIGATION_BTN_UP_SC))));
- m_pNewFolder->SetModeImage(Image(BitmapEx(ModuleRes(BMP_NAVIGATION_CREATEFOLDER_SC))));
+ m_pUp->SetModeImage(Image(BitmapEx(BMP_NAVIGATION_BTN_UP_SC)));
+ m_pNewFolder->SetModeImage(Image(BitmapEx(BMP_NAVIGATION_CREATEFOLDER_SC)));
m_pView->SetDoubleClickHdl( LINK( this, OCollectionView, Dbl_Click_FileView ) );
m_pView->EnableAutoResize();
diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index 715c0f33ba6d..cd11cc5b45ed 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -23,6 +23,7 @@
#include "indexdialog.hxx"
#include "dbu_dlg.hrc"
+#include "bitmaps.hlst"
#include "dbaccess_helpid.hrc"
#include "indexfieldscontrol.hxx"
#include "indexcollection.hxx"
@@ -281,7 +282,7 @@ namespace dbaui
void DbaIndexDialog::fillIndexList()
{
- Image aPKeyIcon(BitmapEx(ModuleRes(BMP_PKEYICON)));
+ Image aPKeyIcon(BitmapEx(BMP_PKEYICON));
// fill the list with the index names
m_pIndexList->Clear();
Indexes::const_iterator aIndexLoop = m_pIndexes->begin();
diff --git a/dbaccess/source/ui/dlg/indexdialog.src b/dbaccess/source/ui/dlg/indexdialog.src
index eaaae1bd2f1d..2a9291883a9b 100644
--- a/dbaccess/source/ui/dlg/indexdialog.src
+++ b/dbaccess/source/ui/dlg/indexdialog.src
@@ -52,11 +52,6 @@ String STR_LOGICAL_INDEX_NAME
Text [ en-US ] = "index";
};
-Bitmap BMP_PKEYICON
-{
- File = "pkey.png";
-};
-
String STR_NEED_INDEX_FIELDS
{
Text [ en-US ] = "The index must contain at least one field.";
diff --git a/dbaccess/source/ui/dlg/sqlmessage.cxx b/dbaccess/source/ui/dlg/sqlmessage.cxx
index 56bed0d40fcd..b4a95c461dd4 100644
--- a/dbaccess/source/ui/dlg/sqlmessage.cxx
+++ b/dbaccess/source/ui/dlg/sqlmessage.cxx
@@ -19,6 +19,7 @@
#include "sqlmessage.hxx"
#include "dbu_dlg.hrc"
+#include "bitmaps.hlst"
#include <com/sun/star/sdbc/SQLException.hpp>
#include <com/sun/star/sdb/SQLContext.hpp>
#include <vcl/fixed.hxx>
@@ -58,12 +59,12 @@ namespace
class ImageProvider
{
private:
- sal_uInt16 m_defaultImageID;
+ OUString m_defaultImageID;
mutable Image m_defaultImage;
public:
- explicit ImageProvider( sal_uInt16 _defaultImageID )
+ explicit ImageProvider(const OUString& _defaultImageID)
:m_defaultImageID( _defaultImageID )
{
}
@@ -71,7 +72,7 @@ namespace
Image const & getImage() const
{
if ( !m_defaultImage )
- m_defaultImage = Image(BitmapEx(ModuleRes(m_defaultImageID)));
+ m_defaultImage = Image(BitmapEx(m_defaultImageID));
return m_defaultImage;
}
};
@@ -110,18 +111,18 @@ namespace
std::shared_ptr< ImageProvider > const & getImageProvider( SQLExceptionInfo::TYPE _eType ) const
{
std::shared_ptr< ImageProvider >* ppProvider( &m_pErrorImage );
- sal_uInt16 nNormalImageID( BMP_EXCEPTION_ERROR );
+ OUString sNormalImageID(BMP_EXCEPTION_ERROR);
switch ( _eType )
{
case SQLExceptionInfo::TYPE::SQLWarning:
ppProvider = &m_pWarningsImage;
- nNormalImageID = BMP_EXCEPTION_WARNING;
+ sNormalImageID = BMP_EXCEPTION_WARNING;
break;
case SQLExceptionInfo::TYPE::SQLContext:
ppProvider = &m_pInfoImage;
- nNormalImageID = BMP_EXCEPTION_INFO;
+ sNormalImageID = BMP_EXCEPTION_INFO;
break;
default:
@@ -129,7 +130,7 @@ namespace
}
if ( !ppProvider->get() )
- ppProvider->reset( new ImageProvider( nNormalImageID ) );
+ ppProvider->reset(new ImageProvider(sNormalImageID));
return *ppProvider;
}
diff --git a/dbaccess/source/ui/dlg/sqlmessage.src b/dbaccess/source/ui/dlg/sqlmessage.src
index c773173f2f97..7a288b5e7f87 100644
--- a/dbaccess/source/ui/dlg/sqlmessage.src
+++ b/dbaccess/source/ui/dlg/sqlmessage.src
@@ -20,21 +20,6 @@
#include "dbaccess_helpid.hrc"
#include "dbu_dlg.hrc"
-Bitmap BMP_EXCEPTION_ERROR
-{
- File = "exerror.png";
-};
-
-Bitmap BMP_EXCEPTION_WARNING
-{
- File = "exwarning.png";
-};
-
-Bitmap BMP_EXCEPTION_INFO
-{
- File = "exinfo.png";
-};
-
String STR_EXCEPTION_STATUS
{
Text [ en-US ] = "SQL Status";
diff --git a/dbaccess/source/ui/imagelists/dbimagelists.src b/dbaccess/source/ui/imagelists/dbimagelists.src
deleted file mode 100644
index 9eabea7a038c..000000000000
--- a/dbaccess/source/ui/imagelists/dbimagelists.src
+++ /dev/null
@@ -1,119 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "dbu_dlg.hrc"
-#include "browserids.hxx"
-
-Bitmap BMP_FORMFOLDER_TREE_L
-{
- File = "forms_32";
-};
-
-Bitmap BMP_REPORTFOLDER_TREE_L
-{
- File = "reports_32";
-};
-
-Bitmap BMP_QUERYFOLDER_TREE_L
-{
- File = "queries_32";
-};
-
-Bitmap BMP_TABLEFOLDER_TREE_L
-{
- File = "tables_32";
-};
-
-// database object icons
-
-// the whole database
-
-Bitmap DATABASE_TREE_ICON
-{
- File = "db.png";
-};
-
-// tables and table folders
-
-Bitmap TABLE_TREE_ICON
-{
- File = "sx03188.png";
-};
-
-Bitmap TABLEFOLDER_TREE_ICON
-{
- File = "sx03187.png";
-};
-
-// views
-
-Bitmap VIEW_TREE_ICON
-{
- File = "sx16670.png";
-};
-
-// queries and query folders
-
-Bitmap QUERY_TREE_ICON
-{
- File = "sx03202.png";
-};
-
-Bitmap QUERYFOLDER_TREE_ICON
-{
- File = "sx03201.png";
-};
-
-// forms and form folders
-
-Bitmap FORM_TREE_ICON
-{
- File = "form_16";
-};
-
-Bitmap FORMFOLDER_TREE_ICON
-{
- File = "forms_16";
-};
-
-// reports and report folders
-
-Bitmap REPORT_TREE_ICON
-{
- File = "report_16";
-};
-
-Bitmap REPORTFOLDER_TREE_ICON
-{
- File = "reports_16";
-};
-
-// new folder and parent folder
-
-Bitmap BMP_NAVIGATION_BTN_UP_SC
-{
- File = "fp010";
-};
-
-Bitmap BMP_NAVIGATION_CREATEFOLDER_SC
-{
- File = "fp015";
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbu_misc.hrc b/dbaccess/source/ui/inc/dbu_misc.hrc
index 0f68311d4e0c..8c62134ace7a 100644
--- a/dbaccess/source/ui/inc/dbu_misc.hrc
+++ b/dbaccess/source/ui/inc/dbu_misc.hrc
@@ -21,8 +21,6 @@
#include "dbu_resource.hrc"
-#define BMP_UP RID_STR_MISC_START + 0
-#define BMP_DOWN RID_STR_MISC_START + 1
#define STR_WIZ_COLUMN_SELECT_TITEL RID_STR_MISC_START + 2
#define STR_WIZ_TYPE_SELECT_TITEL RID_STR_MISC_START + 3
#define STR_WIZ_NAME_ALREADY_DEFINED RID_STR_MISC_START + 4
diff --git a/dbaccess/source/ui/inc/dbu_resource.hrc b/dbaccess/source/ui/inc/dbu_resource.hrc
index 0160b47aa680..d03ca555844c 100644
--- a/dbaccess/source/ui/inc/dbu_resource.hrc
+++ b/dbaccess/source/ui/inc/dbu_resource.hrc
@@ -94,33 +94,6 @@
// FREE
-// images
-
-#define TABLE_TREE_ICON RID_IMAGE_START + 0
-#define VIEW_TREE_ICON RID_IMAGE_START + 1
-#define TABLEFOLDER_TREE_ICON RID_IMAGE_START + 2
-#define BMP_EXCEPTION_ERROR RID_IMAGE_START + 3
-#define BMP_EXCEPTION_WARNING RID_IMAGE_START + 4
-#define BMP_EXCEPTION_INFO RID_IMAGE_START + 5
-#define QUERYFOLDER_TREE_ICON RID_IMAGE_START + 6
-#define QUERY_TREE_ICON RID_IMAGE_START + 7
-#define DATABASE_TREE_ICON RID_IMAGE_START + 8
-#define BMP_PRIMARY_KEY RID_IMAGE_START + 9
-// free
-#define BMP_PKEYICON RID_IMAGE_START + 12
-// free
-#define REPORTFOLDER_TREE_ICON RID_IMAGE_START + 24
-#define BMP_FORMFOLDER_TREE_L RID_IMAGE_START + 39
-#define BMP_REPORTFOLDER_TREE_L RID_IMAGE_START + 40
-#define BMP_QUERYFOLDER_TREE_L RID_IMAGE_START + 41
-#define BMP_TABLEFOLDER_TREE_L RID_IMAGE_START + 42
-#define BMP_NAVIGATION_BTN_UP_SC RID_IMAGE_START + 47
-#define BMP_NAVIGATION_CREATEFOLDER_SC RID_IMAGE_START + 49
-#define FORM_TREE_ICON RID_IMAGE_START + 51
-#define REPORT_TREE_ICON RID_IMAGE_START + 52
-// free
-#define FORMFOLDER_TREE_ICON RID_IMAGE_START + 55
-
// strings
#define STR_TBL_TITLE RID_STR_GEN_START
#define STR_ERROR_DURING_CREATION RID_STR_GEN_START + 1
diff --git a/dbaccess/source/ui/inc/imageprovider.hxx b/dbaccess/source/ui/inc/imageprovider.hxx
index 0d779f01aa95..f680c3ada06a 100644
--- a/dbaccess/source/ui/inc/imageprovider.hxx
+++ b/dbaccess/source/ui/inc/imageprovider.hxx
@@ -106,9 +106,7 @@ namespace dbaui
the resource ID image to be used for the object type. Must be fed into a
ModuleRes instance to actually load the image.
*/
- static sal_uInt16 getDefaultImageResourceID(
- sal_Int32 _nDatabaseObjectType
- );
+ static OUString getDefaultImageResourceID(sal_Int32 _nDatabaseObjectType);
/** retrieves the image to be used for folders of database objects
@param _nDatabaseObjectType
diff --git a/dbaccess/source/ui/misc/WNameMatch.cxx b/dbaccess/source/ui/misc/WNameMatch.cxx
index 410d6a01942b..1724b643d1da 100644
--- a/dbaccess/source/ui/misc/WNameMatch.cxx
+++ b/dbaccess/source/ui/misc/WNameMatch.cxx
@@ -23,18 +23,21 @@
#include "WCopyTable.hxx"
#include "dbaccess_helpid.hrc"
#include "dbu_misc.hrc"
+#include "bitmaps.hlst"
#include <vcl/scrbar.hxx>
#include <vcl/settings.hxx>
#include <vcl/builderfactory.hxx>
#include "svtools/treelistentry.hxx"
#include <com/sun/star/sdbc/DataType.hpp>
#include <o3tl/make_unique.hxx>
+
using namespace ::dbaui;
+
// OWizColumnSelect
-OWizNameMatching::OWizNameMatching( vcl::Window* pParent)
- :OWizardPage( pParent, "NameMatching", "dbaccess/ui/namematchingpage.ui" )
- , m_aImgUp(BitmapEx(ModuleRes(BMP_UP)))
- , m_aImgDown(BitmapEx(ModuleRes(BMP_DOWN)))
+OWizNameMatching::OWizNameMatching(vcl::Window* pParent)
+ : OWizardPage(pParent, "NameMatching", "dbaccess/ui/namematchingpage.ui")
+ , m_aImgUp(BitmapEx(BMP_UP))
+ , m_aImgDown(BitmapEx(BMP_DOWN))
{
get(m_pTABLE_LEFT, "leftlabel");
get(m_pTABLE_RIGHT, "rightlabel");
diff --git a/dbaccess/source/ui/misc/WTypeSelect.cxx b/dbaccess/source/ui/misc/WTypeSelect.cxx
index 4d3a0961a435..429339e3899a 100644
--- a/dbaccess/source/ui/misc/WTypeSelect.cxx
+++ b/dbaccess/source/ui/misc/WTypeSelect.cxx
@@ -19,6 +19,7 @@
#include "WTypeSelect.hxx"
#include "dbustrings.hrc"
+#include "bitmaps.hlst"
#include <tools/diagnose_ex.h>
#include <osl/diagnose.h>
#include "FieldDescriptions.hxx"
@@ -234,7 +235,7 @@ OWizTypeSelect::OWizTypeSelect( vcl::Window* pParent, SvStream* _pStream )
m_pColumnNames->SetSelectHdl(LINK(this,OWizTypeSelect,ColumnSelectHdl));
- m_imgPKey = Image(BitmapEx(ModuleRes(BMP_PRIMARY_KEY)));
+ m_imgPKey = Image(BitmapEx(BMP_PRIMARY_KEY));
m_pTypeControl->Show();
m_pTypeControl->Init();
diff --git a/dbaccess/source/ui/misc/WizardPages.src b/dbaccess/source/ui/misc/WizardPages.src
index 7c4f403cd5c0..5f1b15426ee4 100644
--- a/dbaccess/source/ui/misc/WizardPages.src
+++ b/dbaccess/source/ui/misc/WizardPages.src
@@ -56,16 +56,6 @@ String STR_WIZ_PB_OK
Text [ en-US ] = "C~reate";
};
-Bitmap BMP_UP
-{
- File = "sortup.png" ;
-};
-
-Bitmap BMP_DOWN
-{
- File = "sortdown.png" ;
-};
-
String STR_WIZ_TABLE_COPY
{
Text [ en-US ] = "Copy table" ;
diff --git a/dbaccess/source/ui/misc/imageprovider.cxx b/dbaccess/source/ui/misc/imageprovider.cxx
index 6e4db31a9c1c..80ceaa47f7e5 100644
--- a/dbaccess/source/ui/misc/imageprovider.cxx
+++ b/dbaccess/source/ui/misc/imageprovider.cxx
@@ -21,6 +21,7 @@
#include "dbu_resource.hrc"
#include "moduledbu.hxx"
#include "dbustrings.hrc"
+#include "bitmaps.hlst"
#include <com/sun/star/graphic/XGraphic.hpp>
#include <com/sun/star/graphic/GraphicColorMode.hpp>
@@ -73,9 +74,9 @@ namespace dbaui
}
void lcl_getTableImageResourceID_nothrow( const ImageProvider_Data& _rData, const OUString& _rName,
- sal_uInt16& _out_rResourceID)
+ OUString& _out_rResourceID)
{
- _out_rResourceID = 0;
+ _out_rResourceID = OUString();
try
{
bool bIsView = _rData.xViews.is() && _rData.xViews->hasByName( _rName );
@@ -136,11 +137,11 @@ namespace dbaui
if ( !_out_rImage )
{
// no -> determine by type
- sal_uInt16 nImageResourceID = 0;
- lcl_getTableImageResourceID_nothrow( *m_pData, _rName, nImageResourceID );
+ OUString sImageResourceID;
+ lcl_getTableImageResourceID_nothrow( *m_pData, _rName, sImageResourceID );
- if ( nImageResourceID && !_out_rImage )
- _out_rImage = Image(BitmapEx(ModuleRes(nImageResourceID)));
+ if (!sImageResourceID.isEmpty() && !_out_rImage)
+ _out_rImage = Image(BitmapEx(sImageResourceID));
}
}
}
@@ -148,52 +149,52 @@ namespace dbaui
Image ImageProvider::getDefaultImage( sal_Int32 _nDatabaseObjectType )
{
Image aObjectImage;
- sal_uInt16 nImageResourceID( getDefaultImageResourceID( _nDatabaseObjectType) );
- if ( nImageResourceID )
- aObjectImage = Image(BitmapEx(ModuleRes(nImageResourceID)));
+ OUString sImageResourceID( getDefaultImageResourceID( _nDatabaseObjectType) );
+ if (!sImageResourceID.isEmpty())
+ aObjectImage = Image(BitmapEx(sImageResourceID));
return aObjectImage;
}
- sal_uInt16 ImageProvider::getDefaultImageResourceID( sal_Int32 _nDatabaseObjectType)
+ OUString ImageProvider::getDefaultImageResourceID( sal_Int32 _nDatabaseObjectType)
{
- sal_uInt16 nImageResourceID( 0 );
+ OUString sImageResourceID;
switch ( _nDatabaseObjectType )
{
case DatabaseObject::QUERY:
- nImageResourceID = QUERY_TREE_ICON;
+ sImageResourceID = QUERY_TREE_ICON;
break;
case DatabaseObject::FORM:
- nImageResourceID = FORM_TREE_ICON;
+ sImageResourceID = FORM_TREE_ICON;
break;
case DatabaseObject::REPORT:
- nImageResourceID = REPORT_TREE_ICON;
+ sImageResourceID = REPORT_TREE_ICON;
break;
case DatabaseObject::TABLE:
- nImageResourceID = TABLE_TREE_ICON;
+ sImageResourceID = TABLE_TREE_ICON;
break;
default:
OSL_FAIL( "ImageProvider::getDefaultImage: invalid database object type!" );
break;
}
- return nImageResourceID;
+ return sImageResourceID;
}
Image ImageProvider::getFolderImage( sal_Int32 _nDatabaseObjectType )
{
- sal_uInt16 nImageResourceID( 0 );
+ OUString sImageResourceID;
switch ( _nDatabaseObjectType )
{
case DatabaseObject::QUERY:
- nImageResourceID = QUERYFOLDER_TREE_ICON;
+ sImageResourceID = QUERYFOLDER_TREE_ICON;
break;
case DatabaseObject::FORM:
- nImageResourceID = FORMFOLDER_TREE_ICON;
+ sImageResourceID = FORMFOLDER_TREE_ICON;
break;
case DatabaseObject::REPORT:
- nImageResourceID = REPORTFOLDER_TREE_ICON;
+ sImageResourceID = REPORTFOLDER_TREE_ICON;
break;
case DatabaseObject::TABLE:
- nImageResourceID = TABLEFOLDER_TREE_ICON;
+ sImageResourceID = TABLEFOLDER_TREE_ICON;
break;
default:
OSL_FAIL( "ImageProvider::getDefaultImage: invalid database object type!" );
@@ -201,14 +202,14 @@ namespace dbaui
}
Image aFolderImage;
- if ( nImageResourceID )
- aFolderImage = Image(BitmapEx(ModuleRes(nImageResourceID)));
+ if (!sImageResourceID.isEmpty())
+ aFolderImage = Image(BitmapEx(sImageResourceID));
return aFolderImage;
}
Image ImageProvider::getDatabaseImage()
{
- return Image(BitmapEx(ModuleRes(DATABASE_TREE_ICON)));
+ return Image(BitmapEx(DATABASE_TREE_ICON));
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/querydesign/TableWindow.cxx b/dbaccess/source/ui/querydesign/TableWindow.cxx
index e186e6b1a1f2..e133b59bd093 100644
--- a/dbaccess/source/ui/querydesign/TableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindow.cxx
@@ -37,6 +37,7 @@
#include "querycontroller.hxx"
#include "dbu_qry.hrc"
#include "dbustrings.hrc"
+#include "bitmaps.hlst"
#include <comphelper/extract.hxx>
#include "UITools.hxx"
#include "TableWindowAccess.hxx"
@@ -194,7 +195,7 @@ bool OTableWindow::FillListBox()
}
// mark all primary keys with special image
- Image aPrimKeyImage = Image(BitmapEx(ModuleRes(BMP_PRIMARY_KEY)));
+ Image aPrimKeyImage = Image(BitmapEx(BMP_PRIMARY_KEY));
if (GetData()->IsShowAll())
{
diff --git a/dbaccess/source/ui/querydesign/query.src b/dbaccess/source/ui/querydesign/query.src
index d96f0c3632e7..41ad25620ac0 100644
--- a/dbaccess/source/ui/querydesign/query.src
+++ b/dbaccess/source/ui/querydesign/query.src
@@ -21,11 +21,6 @@
#include "browserids.hxx"
#include "dbaccess_helpid.hrc"
-Bitmap BMP_PRIMARY_KEY
-{
- File = "jo01.png";
-};
-
String STR_QUERY_UNDO_TABWINSHOW
{
Text [ en-US ] = "Add Table Window" ;