From f2ac486e21c64b664dea527e2621e3c1d830c2cc Mon Sep 17 00:00:00 2001 From: Jay Yang Date: Sat, 11 Jun 2011 17:42:17 -0400 Subject: [PATCH] explorer: Implement the explorer using IExplorerBrowser. --- configure | 2 +- configure.ac | 2 +- po/ar.po | 4 + po/bg.po | 5 + po/ca.po | 4 + po/cs.po | 5 + po/da.po | 5 + po/de.po | 5 + po/el.po | 4 + po/en.po | 4 + po/en_US.po | 4 + po/eo.po | 5 + po/es.po | 5 + po/fa.po | 4 + po/fi.po | 5 + po/fr.po | 5 + po/he.po | 5 + po/hi.po | 4 + po/hu.po | 5 + po/it.po | 5 + po/ja.po | 5 + po/ko.po | 5 + po/lt.po | 5 + po/ml.po | 4 + po/nb_NO.po | 5 + po/nl.po | 5 + po/or.po | 4 + po/pa.po | 4 + po/pl.po | 5 + po/pt_BR.po | 5 + po/pt_PT.po | 5 + po/rm.po | 5 + po/ro.po | 5 + po/ru.po | 5 + po/sk.po | 5 + po/sl.po | 5 + po/sr_RS@cyrillic.po | 5 + po/sr_RS@latin.po | 5 + po/sv.po | 5 + po/te.po | 4 + po/th.po | 4 + po/tr.po | 5 + po/uk.po | 5 + po/wa.po | 5 + po/wine.pot | 4 + po/zh_CN.po | 5 + po/zh_TW.po | 5 + programs/explorer/Makefile.in | 5 +- programs/explorer/explorer.c | 208 +++++++++++++++++++++++++--------- programs/explorer/explorer.rc | 29 +++++ programs/explorer/resource.h | 26 +++++ 51 files changed, 428 insertions(+), 56 deletions(-) create mode 100644 programs/explorer/explorer.rc create mode 100644 programs/explorer/resource.h diff --git a/configure b/configure index 245662417f5..92586f2956d 100755 --- a/configure +++ b/configure @@ -15473,7 +15473,7 @@ wine_fn_config_program control enable_control install wine_fn_config_program dxdiag enable_dxdiag install,po wine_fn_config_program eject enable_eject install wine_fn_config_program expand enable_expand install -wine_fn_config_program explorer enable_explorer install +wine_fn_config_program explorer enable_explorer install,po wine_fn_config_program extrac32 enable_extrac32 install wine_fn_config_program hh enable_hh install wine_fn_config_program hostname enable_hostname install,po diff --git a/configure.ac b/configure.ac index 2ae64f76ee7..2e20f247eae 100644 --- a/configure.ac +++ b/configure.ac @@ -2946,7 +2946,7 @@ WINE_CONFIG_PROGRAM(control,,[install]) WINE_CONFIG_PROGRAM(dxdiag,,[install,po]) WINE_CONFIG_PROGRAM(eject,,[install]) WINE_CONFIG_PROGRAM(expand,,[install]) -WINE_CONFIG_PROGRAM(explorer,,[install]) +WINE_CONFIG_PROGRAM(explorer,,[install,po]) WINE_CONFIG_PROGRAM(extrac32,,[install]) WINE_CONFIG_PROGRAM(hh,,[install]) WINE_CONFIG_PROGRAM(hostname,,[install,po]) diff --git a/po/ar.po b/po/ar.po index 1a4e505c6e9..b812f5e4a15 100644 --- a/po/ar.po +++ b/po/ar.po @@ -8085,6 +8085,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/bg.po b/po/bg.po index 25523f869f3..fa6258d1bfd 100644 --- a/po/bg.po +++ b/po/bg.po @@ -8261,6 +8261,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "&Разгледай" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/ca.po b/po/ca.po index ab2397f7ebd..5d306e5a879 100644 --- a/po/ca.po +++ b/po/ca.po @@ -8008,6 +8008,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/cs.po b/po/cs.po index ee5f2a143c4..7f230e75c55 100644 --- a/po/cs.po +++ b/po/cs.po @@ -8640,6 +8640,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "P&rozkoumat" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/da.po b/po/da.po index 31c70464bd1..17309a2cf1b 100644 --- a/po/da.po +++ b/po/da.po @@ -8664,6 +8664,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/de.po b/po/de.po index bb0540744d1..c6e2ac0add8 100644 --- a/po/de.po +++ b/po/de.po @@ -8653,6 +8653,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/el.po b/po/el.po index ff228790766..412cf0c0a40 100644 --- a/po/el.po +++ b/po/el.po @@ -8132,6 +8132,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/en.po b/po/en.po index 890dad69c58..9493c23297a 100644 --- a/po/en.po +++ b/po/en.po @@ -8309,6 +8309,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "Wine Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/en_US.po b/po/en_US.po index 95062418dae..17b165c4dd1 100644 --- a/po/en_US.po +++ b/po/en_US.po @@ -8401,6 +8401,10 @@ msgstr "DirectX Diagnostic Tool" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "Wine Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "Usage: hostname\n" diff --git a/po/eo.po b/po/eo.po index 2676ae4cf4e..5c7a8f68014 100644 --- a/po/eo.po +++ b/po/eo.po @@ -8252,6 +8252,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "E&sploru" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/es.po b/po/es.po index b53a84fcc4f..1f096c13adc 100644 --- a/po/es.po +++ b/po/es.po @@ -8842,6 +8842,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Internet Explorer de Wine" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/fa.po b/po/fa.po index 417119ae439..60af20d38bf 100644 --- a/po/fa.po +++ b/po/fa.po @@ -8087,6 +8087,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/fi.po b/po/fi.po index 73face2a134..366610ad184 100644 --- a/po/fi.po +++ b/po/fi.po @@ -8333,6 +8333,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "&Selaa" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/fr.po b/po/fr.po index caa316bc2e9..b84114a0b18 100644 --- a/po/fr.po +++ b/po/fr.po @@ -8482,6 +8482,11 @@ msgstr "Outil de diagnostic DirectX" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "Usage : dxdiag [/whql:off | /whql:on] [/t fichier | /x fichier]" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Internet Explorer de Wine" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "Usage : hostname\n" diff --git a/po/he.po b/po/he.po index 16ec7f51ba9..d4613838cc1 100644 --- a/po/he.po +++ b/po/he.po @@ -8502,6 +8502,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/hi.po b/po/hi.po index 03029db4788..dd4fe80960d 100644 --- a/po/hi.po +++ b/po/hi.po @@ -8005,6 +8005,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/hu.po b/po/hu.po index 9d013170418..45cdc85743b 100644 --- a/po/hu.po +++ b/po/hu.po @@ -8527,6 +8527,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/it.po b/po/it.po index 4bd9a383ad5..8ec758aeeb7 100644 --- a/po/it.po +++ b/po/it.po @@ -8747,6 +8747,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Internet Explorer di Wine" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/ja.po b/po/ja.po index 887e7bc467e..b994a2d9acc 100644 --- a/po/ja.po +++ b/po/ja.po @@ -8399,6 +8399,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine インターネット エクスプローラ" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "使い方: hostname\n" diff --git a/po/ko.po b/po/ko.po index 2469a0d4a15..4f9267955a6 100644 --- a/po/ko.po +++ b/po/ko.po @@ -8371,6 +8371,11 @@ msgstr "다이렉트엑스 진단 도구" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "사용법: dxdiag [/whql:off | /whql:on] [/t 파일이름 | /x 파일이름]" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine 인터넷 익스폴로어r" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "사용법:hostname\n" diff --git a/po/lt.po b/po/lt.po index 0086355e997..18aede50ee6 100644 --- a/po/lt.po +++ b/po/lt.po @@ -8417,6 +8417,11 @@ msgstr "DirectX diagnostikos įrankis" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "Naudojimas: dxdiag [/whql:off | /whql:on] [/t failas | /x failas]" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine interneto naršyklė" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "Naudojimas: hostname\n" diff --git a/po/ml.po b/po/ml.po index a86eb911110..f55669100f5 100644 --- a/po/ml.po +++ b/po/ml.po @@ -8005,6 +8005,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/nb_NO.po b/po/nb_NO.po index 439e5b90756..1877d1632e6 100644 --- a/po/nb_NO.po +++ b/po/nb_NO.po @@ -8669,6 +8669,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/nl.po b/po/nl.po index 9d84d7bed6d..349dfd5816d 100644 --- a/po/nl.po +++ b/po/nl.po @@ -8555,6 +8555,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Verkenner" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/or.po b/po/or.po index bae55f4d96e..0ca12742131 100644 --- a/po/or.po +++ b/po/or.po @@ -8005,6 +8005,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/pa.po b/po/pa.po index b7ec7177dcf..b85cdc5a30e 100644 --- a/po/pa.po +++ b/po/pa.po @@ -8005,6 +8005,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/pl.po b/po/pl.po index e5ff81a8c32..4757f34afac 100644 --- a/po/pl.po +++ b/po/pl.po @@ -8419,6 +8419,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/pt_BR.po b/po/pt_BR.po index 64f4c44a784..ec1ba87c5b3 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -8694,6 +8694,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/pt_PT.po b/po/pt_PT.po index 55d0c826c60..1eeb7091440 100644 --- a/po/pt_PT.po +++ b/po/pt_PT.po @@ -8747,6 +8747,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Explorador de Internet Wine" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/rm.po b/po/rm.po index ddda4912b17..ce20637da2f 100644 --- a/po/rm.po +++ b/po/rm.po @@ -8055,6 +8055,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine ag�d" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/ro.po b/po/ro.po index 4cc41a3a186..04c7a7c20d6 100644 --- a/po/ro.po +++ b/po/ro.po @@ -8980,6 +8980,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/ru.po b/po/ru.po index 69faa370682..1f04849ecf3 100644 --- a/po/ru.po +++ b/po/ru.po @@ -8416,6 +8416,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/sk.po b/po/sk.po index 6e8fa41207f..ac10f59f262 100644 --- a/po/sk.po +++ b/po/sk.po @@ -8288,6 +8288,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "E&xplore" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/sl.po b/po/sl.po index ad452c8ead6..799e24f1586 100644 --- a/po/sl.po +++ b/po/sl.po @@ -8449,6 +8449,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/sr_RS@cyrillic.po b/po/sr_RS@cyrillic.po index f8e76f8678d..7a5af827e57 100644 --- a/po/sr_RS@cyrillic.po +++ b/po/sr_RS@cyrillic.po @@ -8394,6 +8394,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/sr_RS@latin.po b/po/sr_RS@latin.po index b99957eb7c6..4be5f2551ef 100644 --- a/po/sr_RS@latin.po +++ b/po/sr_RS@latin.po @@ -8448,6 +8448,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/sv.po b/po/sv.po index 46cc06ec354..280730a7fd8 100644 --- a/po/sv.po +++ b/po/sv.po @@ -8417,6 +8417,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/te.po b/po/te.po index 6f52bc7f461..ce8996ad65b 100644 --- a/po/te.po +++ b/po/te.po @@ -8005,6 +8005,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/th.po b/po/th.po index 54f640aaed7..2833692aaed 100644 --- a/po/th.po +++ b/po/th.po @@ -8141,6 +8141,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/tr.po b/po/tr.po index 0596a32d585..6e008d070b7 100644 --- a/po/tr.po +++ b/po/tr.po @@ -8788,6 +8788,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "A&raştır" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/uk.po b/po/uk.po index 6ff64f6c89e..fa58daf1cce 100644 --- a/po/uk.po +++ b/po/uk.po @@ -8426,6 +8426,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Оглядач Інтернету Wine" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/wa.po b/po/wa.po index c60347c70b7..a7b8a6eafa5 100644 --- a/po/wa.po +++ b/po/wa.po @@ -8104,6 +8104,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "E&xplore" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/wine.pot b/po/wine.pot index eed18ef7b8e..ca987ede4ca 100644 --- a/po/wine.pot +++ b/po/wine.pot @@ -7981,6 +7981,10 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +msgid "Wine Explorer" +msgstr "" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/zh_CN.po b/po/zh_CN.po index ae538b2336e..55238076c2c 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -8381,6 +8381,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/po/zh_TW.po b/po/zh_TW.po index 269b4e613af..7a1a5974a26 100644 --- a/po/zh_TW.po +++ b/po/zh_TW.po @@ -8436,6 +8436,11 @@ msgstr "" msgid "Usage: dxdiag [/whql:off | /whql:on] [/t filename | /x filename]" msgstr "" +#: explorer.rc:28 +#, fuzzy +msgid "Wine Explorer" +msgstr "Wine Internet Explorer" + #: hostname.rc:27 msgid "Usage: hostname\n" msgstr "" diff --git a/programs/explorer/Makefile.in b/programs/explorer/Makefile.in index 5537bc4f890..6fe3faebc7f 100644 --- a/programs/explorer/Makefile.in +++ b/programs/explorer/Makefile.in @@ -2,7 +2,7 @@ EXTRADEFS = -DWINE_NO_UNICODE_MACROS MODULE = explorer.exe APPMODE = -mwindows -municode IMPORTS = rpcrt4 user32 gdi32 advapi32 -DELAYIMPORTS = comctl32 +DELAYIMPORTS = comctl32 shell32 ole32 C_SRCS = \ appbar.c \ @@ -10,4 +10,7 @@ C_SRCS = \ explorer.c \ systray.c +RC_SRCS = explorer.rc +PO_SRCS = explorer.rc + @MAKE_PROG_RULES@ diff --git a/programs/explorer/explorer.c b/programs/explorer/explorer.c index 16dcf72b23d..91347ebc425 100644 --- a/programs/explorer/explorer.c +++ b/programs/explorer/explorer.c @@ -3,6 +3,7 @@ * * Copyright 2004 CodeWeavers, Mike Hearn * Copyright 2005,2006 CodeWeavers, Aric Stewart + * Copyright 2011 Jay Yang * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,10 +20,30 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include +#define COBJMACROS #include "wine/unicode.h" +#include "wine/debug.h" #include "explorer_private.h" +#include "resource.h" + +#include +#include +#include +#include + + +WINE_DEFAULT_DEBUG_CHANNEL(explorer); + +#define EXPLORER_INFO_INDEX 0 + +#define DEFAULT_WIDTH 640 +#define DEFAULT_HEIGHT 480 + + +static const WCHAR EXPLORER_CLASS[] = {'W','I','N','E','_','E','X','P','L','O','R','E','R','\0'}; + +HINSTANCE explorer_hInstance; typedef struct parametersTAG { BOOL explorer_mode; @@ -30,8 +51,116 @@ typedef struct parametersTAG { WCHAR selection[MAX_PATH]; } parameters_struct; +typedef struct +{ + IExplorerBrowser *browser; +} explorer_info; -static int CopyPathString(LPWSTR target, LPWSTR source) +static void make_explorer_window(IShellFolder* startFolder) +{ + RECT explorerRect; + HWND window; + FOLDERSETTINGS fs; + explorer_info *info; + HRESULT hres; + WCHAR explorer_title[100]; + LoadStringW(explorer_hInstance,IDS_EXPLORER_TITLE,explorer_title, + sizeof(explorer_title)/sizeof(WCHAR)); + info = HeapAlloc(GetProcessHeap(),0,sizeof(explorer_info)); + if(!info) + { + WINE_ERR("Could not allocate a explorer_info struct\n"); + return; + } + hres = CoCreateInstance(&CLSID_ExplorerBrowser,NULL,CLSCTX_INPROC_SERVER, + &IID_IExplorerBrowser,(LPVOID*)&info->browser); + if(!SUCCEEDED(hres)) + { + WINE_ERR("Could not obtain an instance of IExplorerBrowser\n"); + HeapFree(GetProcessHeap(),0,info); + return; + } + + window = CreateWindowW(EXPLORER_CLASS,explorer_title,WS_OVERLAPPEDWINDOW, + CW_USEDEFAULT,CW_USEDEFAULT,DEFAULT_WIDTH, + DEFAULT_HEIGHT,NULL,NULL,explorer_hInstance,NULL); + fs.ViewMode = FVM_DETAILS; + fs.fFlags = FWF_AUTOARRANGE; + explorerRect.left = 0; + explorerRect.top = 0; + explorerRect.right = DEFAULT_WIDTH; + explorerRect.bottom = DEFAULT_HEIGHT; + + IExplorerBrowser_Initialize(info->browser,window,&explorerRect,&fs); + IExplorerBrowser_SetOptions(info->browser,EBO_SHOWFRAMES); + SetWindowLongPtrW(window,EXPLORER_INFO_INDEX,(LONG_PTR)info); + IExplorerBrowser_BrowseToObject(info->browser,(IUnknown*)startFolder, + SBSP_ABSOLUTE); + ShowWindow(window,SW_SHOWDEFAULT); + UpdateWindow(window); +} + +static void update_window_size(explorer_info *info, int height, int width) +{ + RECT new_rect; + new_rect.left = 0; + new_rect.top = 0; + new_rect.right = width; + new_rect.bottom = height; + IExplorerBrowser_SetRect(info->browser,NULL,new_rect); +} + +static void do_exit(int code) +{ + OleUninitialize(); + ExitProcess(code); +} + +LRESULT CALLBACK explorer_wnd_proc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + explorer_info *info + = (explorer_info*)GetWindowLongPtrW(hwnd,EXPLORER_INFO_INDEX); + IExplorerBrowser *browser = NULL; + + if(info) + browser = info->browser; + switch(uMsg) + { + case WM_DESTROY: + IExplorerBrowser_Release(browser); + HeapFree(GetProcessHeap(),0,info); + PostQuitMessage(0); + break; + case WM_QUIT: + do_exit(wParam); + case WM_SIZE: + update_window_size(info,HIWORD(lParam),LOWORD(lParam)); + break; + default: + return DefWindowProcW(hwnd,uMsg,wParam,lParam); + } + return 0; +} + +static void register_explorer_window_class(void) +{ + WNDCLASSEXW window_class; + window_class.cbSize = sizeof(WNDCLASSEXW); + window_class.style = 0; + window_class.cbClsExtra = 0; + window_class.cbWndExtra = sizeof(LONG_PTR); + window_class.lpfnWndProc = explorer_wnd_proc; + window_class.hInstance = explorer_hInstance; + window_class.hIcon = NULL; + window_class.hCursor = NULL; + window_class.hbrBackground = NULL; + window_class.lpszMenuName = NULL; + window_class.lpszClassName = EXPLORER_CLASS; + window_class.hIconSm = NULL; + RegisterClassExW(&window_class); +} + +static int copy_path_string(LPWSTR target, LPWSTR source) { INT i = 0; @@ -54,7 +183,7 @@ static int CopyPathString(LPWSTR target, LPWSTR source) } -static void CopyPathRoot(LPWSTR root, LPWSTR path) +static void copy_path_root(LPWSTR root, LPWSTR path) { LPWSTR p,p2; INT i = 0; @@ -86,7 +215,7 @@ static void CopyPathRoot(LPWSTR root, LPWSTR path) * [/root,object] Specifies the root level of the view * [/select,object] parent folder is opened and specified object is selected */ -static void ParseCommandLine(LPWSTR commandline,parameters_struct *parameters) +static void parse_command_line(LPWSTR commandline,parameters_struct *parameters) { static const WCHAR arg_n[] = {'/','n'}; static const WCHAR arg_e[] = {'/','e',','}; @@ -113,15 +242,15 @@ static void ParseCommandLine(LPWSTR commandline,parameters_struct *parameters) else if (strncmpW(p, arg_root, sizeof(arg_root)/sizeof(WCHAR))==0) { p += sizeof(arg_root)/sizeof(WCHAR); - p+=CopyPathString(parameters->root,p); + p+=copy_path_string(parameters->root,p); } else if (strncmpW(p, arg_select, sizeof(arg_select)/sizeof(WCHAR))==0) { p += sizeof(arg_select)/sizeof(WCHAR); - p+=CopyPathString(parameters->selection,p); + p+=copy_path_string(parameters->selection,p); if (!parameters->root[0]) - CopyPathRoot(parameters->root, - parameters->selection); + copy_path_root(parameters->root, + parameters->selection); } else if (strncmpW(p, arg_desktop, sizeof(arg_desktop)/sizeof(WCHAR))==0) { @@ -136,7 +265,7 @@ static void ParseCommandLine(LPWSTR commandline,parameters_struct *parameters) if (p2 && *p2) { /* left over command line is generally the path to be opened */ - CopyPathString(parameters->root,p2); + copy_path_string(parameters->root,p2); } } @@ -145,56 +274,29 @@ int WINAPI wWinMain(HINSTANCE hinstance, LPWSTR cmdline, int cmdshow) { - STARTUPINFOW si; - PROCESS_INFORMATION info; + parameters_struct parameters; - BOOL rc; - static const WCHAR winefile[] = {'\\','w','i','n','e','f','i','l','e','.','e','x','e',0}; - static const WCHAR space[] = {' ',0}; - WCHAR app[MAX_PATH]; - LPWSTR winefile_commandline = NULL; - DWORD len = 0; + HRESULT hres; + MSG msg; + IShellFolder *folder; memset(¶meters,0,sizeof(parameters)); - memset(&si,0,sizeof(STARTUPINFOW)); - - ParseCommandLine(cmdline,¶meters); - len = GetSystemDirectoryW( NULL, 0 ) + sizeof(winefile)/sizeof(WCHAR); - - if (parameters.selection[0]) len += lstrlenW(parameters.selection) + 2; - else if (parameters.root[0]) len += lstrlenW(parameters.root) + 3; - - winefile_commandline = HeapAlloc(GetProcessHeap(),0,len*sizeof(WCHAR)); - GetSystemDirectoryW( app, MAX_PATH - sizeof(winefile)/sizeof(WCHAR) ); - strcatW( app, winefile ); - strcpyW( winefile_commandline, app ); - - if (parameters.selection[0]) + explorer_hInstance = hinstance; + parse_command_line(cmdline,¶meters); + hres = OleInitialize(NULL); + if(!SUCCEEDED(hres)) { - lstrcatW(winefile_commandline,space); - lstrcatW(winefile_commandline,parameters.selection); + WINE_ERR("Could not initialize COM\n"); + ExitProcess(EXIT_FAILURE); } - else if (parameters.root[0]) + register_explorer_window_class(); + SHGetDesktopFolder(&folder); + make_explorer_window(folder); + IShellFolder_Release(folder); + while(GetMessageW( &msg, NULL, 0, 0 ) != 0) { - lstrcatW(winefile_commandline,space); - lstrcatW(winefile_commandline,parameters.root); - if (winefile_commandline[lstrlenW(winefile_commandline)-1]!='\\') - { - static const WCHAR slash[] = {'\\',0}; - lstrcatW(winefile_commandline,slash); - } + TranslateMessage(&msg); + DispatchMessageW(&msg); } - - rc = CreateProcessW(app, winefile_commandline, NULL, NULL, FALSE, 0, NULL, - parameters.root[0] ? parameters.root:NULL, &si, &info); - - HeapFree(GetProcessHeap(),0,winefile_commandline); - - if (!rc) - return 0; - - CloseHandle(info.hThread); - WaitForSingleObject(info.hProcess,INFINITE); - CloseHandle(info.hProcess); return 0; } diff --git a/programs/explorer/explorer.rc b/programs/explorer/explorer.rc new file mode 100644 index 00000000000..acac3351deb --- /dev/null +++ b/programs/explorer/explorer.rc @@ -0,0 +1,29 @@ +/* + * Explorer resources + * + * Copyright 2011 Jay Yang + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "resource.h" + +LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT + +STRINGTABLE +{ + IDS_EXPLORER_TITLE "Wine Explorer" +} diff --git a/programs/explorer/resource.h b/programs/explorer/resource.h new file mode 100644 index 00000000000..f3813b0e91b --- /dev/null +++ b/programs/explorer/resource.h @@ -0,0 +1,26 @@ +/* + * Explorer resource definitions + * + * Copyright 2011 Jay Yang + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __WINE_EXPLORER_RESOURCE_H +#define __WINE_EXPLORER_RESOURCE_H + +#define IDS_EXPLORER_TITLE 1 + +#endif