summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--icon-themes/galaxy/vcl/res/index.pngbin0 -> 256 bytes
-rw-r--r--icon-themes/hicontrast/vcl/res/index.pngbin0 -> 109 bytes
-rw-r--r--icon-themes/human/vcl/res/index.pngbin0 -> 308 bytes
-rw-r--r--icon-themes/industrial/vcl/res/index.pngbin0 -> 308 bytes
-rw-r--r--icon-themes/oxygen/vcl/res/index.pngbin0 -> 308 bytes
-rw-r--r--vcl/inc/svids.hrc1
-rw-r--r--vcl/source/src/images.src5
-rw-r--r--vcl/source/window/builder.cxx18
8 files changed, 23 insertions, 1 deletions
diff --git a/icon-themes/galaxy/vcl/res/index.png b/icon-themes/galaxy/vcl/res/index.png
new file mode 100644
index 000000000000..eee0edfcaa56
--- /dev/null
+++ b/icon-themes/galaxy/vcl/res/index.png
Binary files differ
diff --git a/icon-themes/hicontrast/vcl/res/index.png b/icon-themes/hicontrast/vcl/res/index.png
new file mode 100644
index 000000000000..4392542b80b7
--- /dev/null
+++ b/icon-themes/hicontrast/vcl/res/index.png
Binary files differ
diff --git a/icon-themes/human/vcl/res/index.png b/icon-themes/human/vcl/res/index.png
new file mode 100644
index 000000000000..d41d81a5e6c9
--- /dev/null
+++ b/icon-themes/human/vcl/res/index.png
Binary files differ
diff --git a/icon-themes/industrial/vcl/res/index.png b/icon-themes/industrial/vcl/res/index.png
new file mode 100644
index 000000000000..d41d81a5e6c9
--- /dev/null
+++ b/icon-themes/industrial/vcl/res/index.png
Binary files differ
diff --git a/icon-themes/oxygen/vcl/res/index.png b/icon-themes/oxygen/vcl/res/index.png
new file mode 100644
index 000000000000..d41d81a5e6c9
--- /dev/null
+++ b/icon-themes/oxygen/vcl/res/index.png
Binary files differ
diff --git a/vcl/inc/svids.hrc b/vcl/inc/svids.hrc
index e0a64f643cb3..5abe5bd84b51 100644
--- a/vcl/inc/svids.hrc
+++ b/vcl/inc/svids.hrc
@@ -41,6 +41,7 @@
#define SV_RESID_BITMAP_SCROLLMSK 1050
#define SV_RESID_BITMAP_SCROLLBMP 1051
#define SV_RESID_BITMAP_CLOSEDOC 1052
+#define SV_RESID_BITMAP_INDEX 1053
#define SV_DISCLOSURE_PLUS 1060
#define SV_DISCLOSURE_MINUS 1061
diff --git a/vcl/source/src/images.src b/vcl/source/src/images.src
index f0b58f4d82d1..061f59c6b676 100644
--- a/vcl/source/src/images.src
+++ b/vcl/source/src/images.src
@@ -77,6 +77,11 @@ Bitmap SV_RESID_BITMAP_CLOSEDOC
File = "closedoc.png";
};
+Bitmap SV_RESID_BITMAP_INDEX
+{
+ File = "index.png";
+};
+
Bitmap SV_RESID_BITMAP_SPLITHPIN
{
File = "splhpin.png";
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 735bde150d71..20a2b71de725 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -33,6 +33,14 @@
namespace
{
+ sal_uInt16 mapStockToImageResource(OString sType)
+ {
+ sal_uInt16 nRet = 0;
+ if (sType == "gtk-index")
+ nRet = SV_RESID_BITMAP_INDEX;
+ return nRet;
+ }
+
SymbolType mapStockToSymbol(OString sType)
{
SymbolType eRet = SYMBOL_NOSYMBOL;
@@ -54,6 +62,8 @@ namespace
eRet = SYMBOL_HELP;
else if (sType == "gtk-close")
eRet = SYMBOL_CLOSE;
+ else if (mapStockToImageResource(sType))
+ eRet = SYMBOL_IMAGE;
return eRet;
}
}
@@ -168,13 +178,19 @@ VclBuilder::VclBuilder(Window *pParent, OUString sUIDir, OUString sUIFile, OStri
PushButton *pTarget = get<PushButton>(aI->m_sID);
FixedImage *pImage = get<FixedImage>(aI->m_sValue);
aImagesToBeRemoved.insert(aI->m_sValue);
- SymbolType eType = mapStockToSymbol(m_pParserState->m_aStockMap[aI->m_sValue]);
+ const OString &rImage = m_pParserState->m_aStockMap[aI->m_sValue];
+ SymbolType eType = mapStockToSymbol(rImage);
SAL_WARN_IF(!pTarget || !pImage || eType == SYMBOL_NOSYMBOL,
"vcl", "missing elements of button/image/stock");
+ if (!pTarget || eType == SYMBOL_NOSYMBOL)
+ continue;
+
//to-do, situation where image isn't a stock image
if (pTarget && eType != SYMBOL_NOSYMBOL)
{
pTarget->SetSymbol(eType);
+ if (eType == SYMBOL_IMAGE)
+ pTarget->SetModeImage(VclResId(mapStockToImageResource(rImage)));
}
}