Compare commits
567 Commits
Author | SHA1 | Date | |
---|---|---|---|
a71849db3f | |||
a2eb3325ce | |||
b9df78b9c6 | |||
9a3c1ccd72 | |||
68116da5ad | |||
68153812f7 | |||
bb1062ae2a | |||
bdb18828e3 | |||
a903f16c68 | |||
5feeb717a0 | |||
703316ace6 | |||
88afa4afa2 | |||
bf269d2e03 | |||
755932c3bc | |||
4c406bce17 | |||
3a87dedbb5 | |||
731fd33be2 | |||
ffc47e8439 | |||
cc9d6042fd | |||
012b9c478e | |||
5d35ecfaa9 | |||
21bf0ae998 | |||
9d0ea7af4b | |||
08fd4f2dd7 | |||
8f0d6e85fd | |||
7dea09c371 | |||
ce5653d75c | |||
36b84c9af3 | |||
d13046614e | |||
53e30995d6 | |||
0c4e343b46 | |||
e6394cafe2 | |||
fabc5bf4b7 | |||
d601335aa6 | |||
d6dacbe955 | |||
616c669d3b | |||
d52cc1a1bd | |||
43a2f43090 | |||
b3369a4bc4 | |||
b5b547abb6 | |||
4e775df156 | |||
bf0ff98385 | |||
66412e4997 | |||
77c1edbe13 | |||
46c32952b0 | |||
41719bd4a8 | |||
9629ca3fd9 | |||
a3ab5edc59 | |||
8fbcddd2cd | |||
73d63ca3da | |||
721a9965aa | |||
4f77f046d0 | |||
0b95c1c444 | |||
41c0c345cd | |||
c8f6d2c538 | |||
b2d2187b20 | |||
b8894a468d | |||
1c30e0c124 | |||
4dc600a63c | |||
13bfd060b6 | |||
1370a49742 | |||
ab6bf4234c | |||
5224c275e8 | |||
272b3d2f82 | |||
2528a78593 | |||
2917a83d7b | |||
77e9417c7b | |||
e8456beadc | |||
d63a33b6dc | |||
bdc814a4a4 | |||
ce40e5a111 | |||
61c9ad08bf | |||
bca0ad8e1e | |||
6ec7bfad30 | |||
0e76283c9a | |||
78a72a6c1e | |||
4a95b07ae7 | |||
154ea98deb | |||
be252e271f | |||
e2328e7a91 | |||
942b92c796 | |||
3bd2143d9a | |||
93cfa353e7 | |||
2cbe758c80 | |||
72c6834cc5 | |||
ac06b74b18 | |||
1fd94e79b9 | |||
bb3cb269c2 | |||
715a520c0e | |||
78d14a2b1e | |||
3d10b9f3e2 | |||
f97f1a08ae | |||
13e9713b72 | |||
bf9276fc5c | |||
fe86c4900f | |||
f45487e92c | |||
bca972bdc3 | |||
a8abba84bd | |||
2e2f4662f3 | |||
0c87c49146 | |||
6c8d9c2194 | |||
62d52d55b2 | |||
3598966069 | |||
ec6f5b011a | |||
9d4a1a3b4f | |||
9978ebd853 | |||
18eaccb840 | |||
e63ec01089 | |||
e0fb3d537d | |||
19d4356484 | |||
be1e6bde65 | |||
f113008c7f | |||
5e240eb259 | |||
7101b7b864 | |||
98aa62f637 | |||
798db7368a | |||
4cf61ccedb | |||
7f50ee6fd2 | |||
1544a5d6cb | |||
3284502645 | |||
4cc03aba75 | |||
286bbc6bde | |||
d1244d7231 | |||
50219a63ad | |||
806c75f051 | |||
ee621d2435 | |||
340811da6e | |||
4b40597c76 | |||
9a789bc9e7 | |||
4886cc8258 | |||
82277a80ea | |||
22064278df | |||
932bfa3482 | |||
5de5d6d00b | |||
aab55d8cff | |||
73c9321361 | |||
25288120be | |||
d99d951f7f | |||
00e15828a1 | |||
ad926e9b07 | |||
059cbcd406 | |||
dcdb11a78b | |||
aef9e3922e | |||
ce6fef3d0a | |||
4057b7dd58 | |||
d1725e3f44 | |||
42da8fe3ef | |||
a01bd83c64 | |||
6a0240aa18 | |||
179747a7bc | |||
94186f7888 | |||
ac5771377e | |||
863dc2e841 | |||
59b9ee3417 | |||
3285934703 | |||
c7d1102c61 | |||
6e3f05fcc7 | |||
d8286a63ec | |||
9854b100fb | |||
ef5588b9c0 | |||
64ba92593e | |||
33b5dc1c75 | |||
02139fbb79 | |||
9ef1d1db96 | |||
225acd0ce2 | |||
b4496216db | |||
d88c4ad411 | |||
8b217981ed | |||
8ce8a359c1 | |||
55734baed8 | |||
52ce55341b | |||
e4b6f4b375 | |||
32dee82c58 | |||
2870586cf9 | |||
cb1975f450 | |||
805b33552b | |||
6bc05a8bc8 | |||
3ffae231de | |||
6a7557da01 | |||
d7045e2b61 | |||
e68635b8e4 | |||
7ef8d0d443 | |||
9b958ed393 | |||
84e8c658f6 | |||
21a5eb2702 | |||
1d62465e5b | |||
cb1b1c6e1c | |||
8be56d7003 | |||
8ce1a9476d | |||
0689b54827 | |||
b569943059 | |||
eb001433e4 | |||
a591c875ae | |||
08cd36bef0 | |||
5d0599976e | |||
2e014bbc72 | |||
88e9611444 | |||
97e88b885a | |||
f84476cf87 | |||
473ab16739 | |||
951292abe1 | |||
612032c9f8 | |||
0dd9ac2e44 | |||
8f551de4f4 | |||
0c2e08cf2b | |||
0e420fbee8 | |||
cf505b850b | |||
fd762303b0 | |||
a6f05db34b | |||
df0ee53765 | |||
d0b3476839 | |||
4d16f5bf28 | |||
c45cc78548 | |||
d16aedf6c4 | |||
d3a27947fe | |||
42e3587fd5 | |||
e3f699a9d8 | |||
5201f0fd06 | |||
df0e97550b | |||
983b4ace89 | |||
f0684dc74e | |||
39923e05f3 | |||
51bf9165b2 | |||
f1735f3ae1 | |||
2ba785f648 | |||
c9b7a3f86e | |||
43bd9483ce | |||
1277b4c30f | |||
e1ce1c90f7 | |||
f45c2dd061 | |||
855c20501b | |||
945251c6b8 | |||
e47dd3eb89 | |||
c9c8993b9d | |||
d934e60c2b | |||
11478719cd | |||
7284addb09 | |||
270cde42f1 | |||
b690098941 | |||
fffe9f4bd9 | |||
7353bf2698 | |||
133b0f7d94 | |||
4878012065 | |||
4402ea34de | |||
faa53a5335 | |||
44a88fc1ab | |||
d3ce4f64f6 | |||
fcdd85ae5e | |||
fd71bb768a | |||
66bb79ef10 | |||
3b4cc9d806 | |||
79221c403b | |||
0ab11cc09a | |||
1432ecfb33 | |||
341cfbb527 | |||
78573ae0c9 | |||
8a9d3e21f2 | |||
8655c4b007 | |||
5fa23341b3 | |||
67274f91e9 | |||
c0cc6a2c93 | |||
b2fec642fe | |||
d60cecb8d3 | |||
c168a9adc6 | |||
f778245a86 | |||
5701ba287b | |||
c471388021 | |||
9d717ffee9 | |||
bac96d1fa8 | |||
f313a83474 | |||
9891f94e41 | |||
a22ae9f39a | |||
02298c8e76 | |||
73badc67ff | |||
1181b56211 | |||
78eb3e7522 | |||
57b74c3de9 | |||
c83ca8f85a | |||
ef58a267b0 | |||
4130954c15 | |||
0a2af0ab62 | |||
a1a94ed319 | |||
096d0660e2 | |||
b28734c4a8 | |||
69c2893234 | |||
89078eb3b3 | |||
26cefd0587 | |||
8ccd11ee4b | |||
fd1b276aab | |||
2ff8e74061 | |||
0020f81e79 | |||
6f09752db4 | |||
8cf025f18d | |||
81990ce53b | |||
12cdb7704c | |||
947dd45294 | |||
a435e8648f | |||
25d0793766 | |||
5c9652bf13 | |||
7a242a8331 | |||
7cdfeff204 | |||
83107ee222 | |||
d9d05e83ba | |||
631664645d | |||
61ed0829bd | |||
f023de0faf | |||
7238853f0f | |||
6a8cad6f94 | |||
2c15270be1 | |||
c044bdfe32 | |||
aac7079562 | |||
cadcfc553c | |||
5df669a329 | |||
4c307f6ac9 | |||
37aa38617e | |||
07acb6f7b6 | |||
9c96528a98 | |||
9327a5c71f | |||
171dbcdedf | |||
de819e12bf | |||
198dc9eb43 | |||
04d282fae3 | |||
bb86771425 | |||
791e0fc11f | |||
0badd9b874 | |||
af03fa3c7c | |||
4d30512e05 | |||
d5e8fa47f0 | |||
85c7e07351 | |||
fde85c79df | |||
712eb5428e | |||
5c663adf35 | |||
68fa033483 | |||
b33f70571e | |||
cdc2bb0216 | |||
250d9b565c | |||
6e7c0395e1 | |||
be35154376 | |||
de2fdc093a | |||
3679dfe93e | |||
2e1425451d | |||
0e1da0d33d | |||
7b0b86c9f7 | |||
a98b95923b | |||
cf3d1ebb8b | |||
5db1541f95 | |||
873a3ef047 | |||
beb3ab506d | |||
494364d437 | |||
2f1f2c6a85 | |||
66853d9715 | |||
cf59ad2c76 | |||
dba9c42473 | |||
f8556360ca | |||
28fe051aa5 | |||
607e5a567c | |||
df31e239a9 | |||
df7a15e910 | |||
860ef759f5 | |||
4ba79fd489 | |||
fb01d4e9ab | |||
b2317d8800 | |||
3283c71936 | |||
22a0d5a3fb | |||
46443cbd1c | |||
efd21ce982 | |||
c4e96dd481 | |||
65e384523a | |||
80aee2af6c | |||
1f525a6f4b | |||
ffa1ea7358 | |||
ce7eb02601 | |||
ce80e571f2 | |||
11044c6264 | |||
7243f5bc2c | |||
863ff811e6 | |||
414ab39db5 | |||
ba78c0527f | |||
fb696b7a68 | |||
295da18414 | |||
8272df5ec2 | |||
99fed089cf | |||
e3fd501057 | |||
7403dfa9aa | |||
b08d9cfb56 | |||
1969db5f94 | |||
866299b508 | |||
c4384265e4 | |||
b4c885861d | |||
d9be5e098f | |||
0a54efdd0c | |||
708c5a7347 | |||
50373f4ff9 | |||
2df866bdf8 | |||
5b8567919d | |||
77cad8e716 | |||
700d699f5b | |||
87413e9d3c | |||
dbe6deab45 | |||
b2ae3b9dd1 | |||
92dca50dfc | |||
a3ba8d575e | |||
ea48d18130 | |||
4547719358 | |||
bb878848f7 | |||
5bb284267b | |||
7e3c8c461e | |||
24034b5b8b | |||
78f9f3f87c | |||
bc1169e979 | |||
012105e115 | |||
5c5eb1df14 | |||
e714c7d53f | |||
78e39bfb1c | |||
7323f7c561 | |||
c6513ea7a2 | |||
6001ceff9f | |||
8e3db00dac | |||
d20dccbe02 | |||
e834783cb8 | |||
01f24aae07 | |||
584dc6a626 | |||
756080831d | |||
ffce6c5788 | |||
565a492724 | |||
6982bbfef9 | |||
07bc467d03 | |||
a39f8ea71f | |||
4ad9a69aeb | |||
ee200b97aa | |||
fc659a67f0 | |||
de0b0b9467 | |||
eef74ed263 | |||
facf0ab9c4 | |||
5318c953ed | |||
2550a94f05 | |||
bd73c80152 | |||
43cbe83d61 | |||
075c5dfad6 | |||
ba1dfabf11 | |||
9603248a5b | |||
4e891102f2 | |||
bc1c84347d | |||
2db01371b3 | |||
e17a9c6503 | |||
3994126a09 | |||
70174be823 | |||
9254f9284c | |||
c819adf830 | |||
13c717159d | |||
4c90a9b2d5 | |||
a14bd119b7 | |||
f9cf25f797 | |||
450b92f6c0 | |||
9790151ec0 | |||
3fbea449b5 | |||
02cdc57eb5 | |||
d7571ce1e3 | |||
ccc8601624 | |||
7e2ae20ecf | |||
b856065167 | |||
f3efdaf40f | |||
86564c8741 | |||
a5eb7784c6 | |||
f0d0f90e13 | |||
27d828172d | |||
a7ffdf3d65 | |||
dd624950c6 | |||
b407bfa168 | |||
069a6adb19 | |||
9dd2c85df4 | |||
b7f0f6abc8 | |||
ea0479998a | |||
9272eb4325 | |||
4e601cf14c | |||
db582a4e5c | |||
059e4ec9c8 | |||
a96be226b2 | |||
bed00e525d | |||
096e837ece | |||
e67371d269 | |||
a996549577 | |||
9917b7e3df | |||
541f221a61 | |||
44a2ed5a97 | |||
ba3f4daee8 | |||
2d3d4db16b | |||
0c351c9cbc | |||
cc1f2b2d27 | |||
6ee3a4a978 | |||
5326f76a40 | |||
7f86fbad1e | |||
30fa189cbb | |||
2fdb2a8b6f | |||
b07e5fafaf | |||
ba1a1ab28d | |||
a9643234ae | |||
7870c8028f | |||
6510e8961e | |||
6e8b7367d7 | |||
feb5b41642 | |||
36694afe0e | |||
a99111172d | |||
780c3d29c7 | |||
1a7831df2a | |||
924178cde7 | |||
77fa72924b | |||
b90633d406 | |||
cd64e02096 | |||
ad820cef8a | |||
68de2bcb00 | |||
68b6be11d6 | |||
d13ae114a2 | |||
3a6103564e | |||
0424e5a329 | |||
561ad635cd | |||
2427c095e5 | |||
ed27009285 | |||
92654bdd9b | |||
fdf7ec22f5 | |||
3c4a154f0a | |||
c766b24920 | |||
af652a6639 | |||
812628acb2 | |||
6b86940b7b | |||
08d948435d | |||
5004f69b5e | |||
bc5d16c4fb | |||
c2a5b4fb7d | |||
cca8ab4640 | |||
d964af8142 | |||
7746ff9a12 | |||
c4cf67bee4 | |||
a1daf03538 | |||
2be0530c34 | |||
b0d1c884e0 | |||
e0a7f0ae59 | |||
5779691efb | |||
496ed18e85 | |||
86cf7de430 | |||
477d7470c1 | |||
3706b51159 | |||
b4c8d53394 | |||
4c217d4ba3 | |||
23b2081385 | |||
0534b54e51 | |||
faf4575e9a | |||
52efe3abff | |||
59510cf8a1 | |||
905705910b | |||
bb78d8dd59 | |||
8b72d53dcc | |||
ef4aa16730 | |||
14b089ef90 | |||
b5fef8d0e2 | |||
561f3044d6 | |||
9c49254abd | |||
5e59578e28 | |||
7317535c28 | |||
920839cf1c | |||
d8eec06473 | |||
4748405277 | |||
13d574b455 | |||
2b13d0f527 | |||
e054a6512f | |||
eb5313f850 | |||
bf0fb9f327 |
8
.gitignore
vendored
8
.gitignore
vendored
@ -20,6 +20,8 @@ config.sub
|
||||
configure
|
||||
configure.tmp
|
||||
depcomp
|
||||
doxygen*.tmp
|
||||
html/
|
||||
install-sh
|
||||
intl/
|
||||
libtool
|
||||
@ -32,6 +34,7 @@ po/Makefile.in.in
|
||||
po/POTFILES
|
||||
po/remove-potcdate.sed
|
||||
po/stamp-po
|
||||
share/pkgconfig/hexchat-plugin.pc
|
||||
src/common/dbus/example
|
||||
src/common/dbus/marshallers.h
|
||||
src/common/dbus/org.hexchat.service.service
|
||||
@ -41,7 +44,11 @@ src/common/textenums.h
|
||||
src/common/textevents.h
|
||||
src/fe-gtk/hexchat
|
||||
src/fe-text/hexchat-text
|
||||
src/htm/Main.resources
|
||||
src/htm/thememan.exe
|
||||
src/htm/thememan.exe.config
|
||||
src/htm/thememan.exe.mdb
|
||||
src/htm/thememan
|
||||
stamp-h1
|
||||
*.a
|
||||
*.o
|
||||
@ -50,6 +57,7 @@ stamp-h1
|
||||
*.gmo
|
||||
*.mo
|
||||
*.po~
|
||||
*.patch
|
||||
# Win32 generated files
|
||||
plugins/wmpa/wmpa_h.h
|
||||
plugins/wmpa/wmpa_i.c
|
||||
|
14
.travis.yml
Normal file
14
.travis.yml
Normal file
@ -0,0 +1,14 @@
|
||||
language: c
|
||||
compiler: gcc
|
||||
before_script:
|
||||
- sudo apt-get build-dep -qq xchat
|
||||
- sudo apt-get install -qq libnotify-dev libproxy-dev libpci-dev libcanberra-dev monodevelop
|
||||
script:
|
||||
- ./autogen.sh
|
||||
- ./configure --enable-textfe --with-theme-manager
|
||||
- make
|
||||
notifications:
|
||||
irc:
|
||||
channels: "chat.freenode.net#hexchat-devel"
|
||||
template: "Build #%{build_number} (%{commit}) by %{author}: %{message}"
|
||||
on_success: change
|
17
.tx/config
17
.tx/config
@ -1,9 +1,8 @@
|
||||
[main]
|
||||
host = https://www.transifex.com
|
||||
|
||||
[hexchat.main]
|
||||
file_filter = po\<lang>.po
|
||||
source_file = po\hexchat.pot
|
||||
source_lang = en
|
||||
type = PO
|
||||
|
||||
[main]
|
||||
host = https://www.transifex.com
|
||||
|
||||
[hexchat.main]
|
||||
file_filter = po/<lang>.po
|
||||
source_file = po/hexchat.pot
|
||||
source_lang = en
|
||||
type = PO
|
||||
|
@ -1,5 +1,7 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
ACLOCAL_AMFLAGS = -I m4
|
||||
|
||||
SUBDIRS = po intl src plugins man share
|
||||
|
||||
EXTRA_DIST = autogen.sh
|
||||
|
@ -78,7 +78,7 @@ if test "$?" != "0"; then
|
||||
exit 2
|
||||
fi
|
||||
echo running libtoolize...
|
||||
libtoolize --force
|
||||
libtoolize --copy --force --install
|
||||
if test "$?" != "0"; then
|
||||
echo libtoolize failed, stopping.
|
||||
exit 3
|
||||
@ -90,7 +90,7 @@ if test "$?" != "0"; then
|
||||
exit 4
|
||||
fi
|
||||
echo running $AUTOMAKE...
|
||||
$AUTOMAKE -a
|
||||
$AUTOMAKE -a -c
|
||||
if test "$?" != "0"; then
|
||||
echo automake failed, stopping.
|
||||
exit 5
|
||||
|
@ -7,12 +7,12 @@
|
||||
#define USE_IPV6
|
||||
#define HAVE_ISO_CODES
|
||||
#define PACKAGE_NAME "hexchat"
|
||||
#define PACKAGE_VERSION "2.9.5"
|
||||
#define HEXCHATLIBDIR "."
|
||||
#define PACKAGE_VERSION "2.9.6"
|
||||
#define HEXCHATLIBDIR ".\\plugins"
|
||||
#define HEXCHATSHAREDIR "."
|
||||
#define OLD_PERL
|
||||
#define GETTEXT_PACKAGE "hexchat"
|
||||
#define PACKAGE_TARNAME "hexchat-2.9.5"
|
||||
#define PACKAGE_TARNAME "hexchat-2.9.6"
|
||||
#ifndef USE_IPV6
|
||||
#define socklen_t int
|
||||
#endif
|
||||
|
284
configure.ac
284
configure.ac
@ -1,6 +1,6 @@
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_INIT([HexChat],[2.9.5])
|
||||
AC_INIT([HexChat],[2.9.6])
|
||||
|
||||
AC_PREREQ([2.60])
|
||||
AC_COPYRIGHT([Copyright (C) 1998-2010 Peter Zelezny])
|
||||
@ -8,8 +8,9 @@ AC_COPYRIGHT([Copyright (C) 1998-2010 Peter Zelezny])
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
AC_CONFIG_SRCDIR([configure.ac])
|
||||
|
||||
AM_INIT_AUTOMAKE([1.11 dist-bzip2 subdir-objects no-define foreign])
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
|
||||
AM_INIT_AUTOMAKE([1.11 dist-bzip2 subdir-objects no-define foreign])
|
||||
AM_SILENT_RULES([yes])
|
||||
|
||||
AC_USE_SYSTEM_EXTENSIONS
|
||||
@ -20,6 +21,7 @@ AC_PROG_CPP
|
||||
AM_PROG_AS
|
||||
AM_DISABLE_STATIC
|
||||
AC_PROG_LIBTOOL
|
||||
AC_PATH_PROG(MDTOOL, mdtool, no)
|
||||
|
||||
dnl -----------------------------------------------------------
|
||||
dnl Language Support
|
||||
@ -45,6 +47,7 @@ AH_VERBATIM([USE_GTKSPELL],[#undef USE_GTKSPELL])
|
||||
AH_VERBATIM([USE_LIBSEXY],[#undef USE_LIBSEXY])
|
||||
AH_VERBATIM([HAVE_ISO_CODES],[#undef HAVE_ISO_CODES])
|
||||
AH_VERBATIM([USE_LIBNOTIFY],[#undef USE_LIBNOTIFY])
|
||||
AH_VERBATIM([USE_LIBCANBERRA],[#undef USE_LIBCANBERRA])
|
||||
AH_VERBATIM([USE_IPV6],[#undef USE_IPV6])
|
||||
AH_VERBATIM([USE_MMX],[#undef USE_MMX])
|
||||
AH_VERBATIM([USE_OPENSSL],[#undef USE_OPENSSL])
|
||||
@ -114,21 +117,18 @@ AC_ARG_ENABLE(xlib,
|
||||
xlib=$enableval, xlib=yes)
|
||||
|
||||
AC_ARG_ENABLE(python,
|
||||
[AS_HELP_STRING([--enable-python=pythonversion],[build the python plugin (default on, python2)])],
|
||||
[AS_HELP_STRING([--enable-python=pythonversion],[build the python plugin; possible values: "python2", "python3" or specific such as "python3.3" (default on, python2)])],
|
||||
python=$enableval, python=python2)
|
||||
AS_IF([test "x$python" = "xyes"], [python=python2])
|
||||
|
||||
AC_ARG_ENABLE(perl,
|
||||
[AS_HELP_STRING([--disable-perl],[don't build the perl plugin])],
|
||||
[AS_HELP_STRING([--disable-perl],[don\'t build the perl plugin])],
|
||||
perl=$enableval, perl=yes)
|
||||
|
||||
AC_ARG_ENABLE(perl_old,
|
||||
[AS_HELP_STRING([--disable-perl_old],[no backwards compatibility for perl plugin])],
|
||||
perl_old=$enableval, perl_old=yes)
|
||||
|
||||
dnl AC_ARG_ENABLE(tcl,
|
||||
dnl [AS_HELP_STRING([--enable-tcl[=PATH]],[directory with Tcl config file: tclConfig.sh])],
|
||||
dnl tcl=$enableval, tcl=yes)
|
||||
|
||||
AC_ARG_ENABLE(plugin,
|
||||
[AS_HELP_STRING([--disable-plugin],[disable plugin support])],
|
||||
plugin=$enableval, plugin=yes)
|
||||
@ -145,10 +145,6 @@ AC_ARG_ENABLE(fishlim,
|
||||
[AS_HELP_STRING([--disable-fishlim],[disable the FiSHLiM plugin])],
|
||||
fishlim=$enableval, fishlim=yes)
|
||||
|
||||
dnl AC_ARG_ENABLE(sasl,
|
||||
dnl [AS_HELP_STRING([--disable-sasl],[disable the SASL plugin])],
|
||||
dnl sasl=$enableval, sasl=yes)
|
||||
|
||||
AC_ARG_ENABLE(sysinfo,
|
||||
[AS_HELP_STRING([--disable-sysinfo],[disable the SysInfo plugin])],
|
||||
sysinfo=$enableval, sysinfo=yes)
|
||||
@ -161,6 +157,11 @@ AC_ARG_ENABLE(libnotify,
|
||||
[AS_HELP_STRING([--disable-libnotify],[disable libnotify support])],
|
||||
libnotify=$enableval, libnotify=yes)
|
||||
|
||||
AC_ARG_ENABLE(libcanberra,
|
||||
[AS_HELP_STRING([--disable-libcanberra],[disable libcanberra support])],
|
||||
libcanberra=$enableval, libcanberra=yes)
|
||||
|
||||
|
||||
AC_ARG_ENABLE(mmx,
|
||||
[AS_HELP_STRING([--disable-mmx],[disable MMX assembly routines])],
|
||||
mmx=$enableval, mmx=yes)
|
||||
@ -171,29 +172,49 @@ AC_ARG_ENABLE(shm,
|
||||
|
||||
AC_ARG_ENABLE(spell,
|
||||
[AS_HELP_STRING([--enable-spell=type],[enable spelling type: none static libsexy gtkspell])],
|
||||
spell=$enableval, spell=static)
|
||||
spell=$enableval, spell=libsexy)
|
||||
|
||||
AC_ARG_ENABLE(ntlm,
|
||||
[AS_HELP_STRING([--enable-ntlm],[enable Microsoft's NTLM auth (libntlm) library support (default: no)])],
|
||||
[AS_HELP_STRING([--enable-ntlm],[enable Microsoft\'s NTLM auth (libntlm) library support (default: no)])],
|
||||
ntlm=$enableval, ntlm=no)
|
||||
|
||||
AC_ARG_ENABLE(libproxy,
|
||||
[AS_HELP_STRING([--disable-libproxy],[disable libproxy support (default: auto)])],
|
||||
libproxy=$enableval, libproxy=auto)
|
||||
|
||||
AC_ARG_ENABLE(minimal-flags,
|
||||
[AS_HELP_STRING([--enable-minimal-flags],[only add those CFLAGS that are really needed or not intrusive (default: no)])],
|
||||
minimalflags=$enableval, minimalflags=no)
|
||||
|
||||
AC_ARG_WITH(theme-manager,
|
||||
[AS_HELP_STRING([--with-theme-manager],[compile theme manager (needs monodevelop, default: off)])],
|
||||
theme_manager=$withval, theme_manager=no)
|
||||
|
||||
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** THEME-MANAGER ****************************************************
|
||||
dnl *********************************************************************
|
||||
if test "x$theme_manager" != "xno" ; then
|
||||
if test "x$MDTOOL" = "xno"; then
|
||||
AC_MSG_ERROR([No "mdtool" found, you need to install monodevelop!])
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** GLIB *************************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
AM_PATH_GLIB_2_0(2.14.0, glib=yes, glib=no)
|
||||
AM_PATH_GLIB_2_0(2.28.0, glib=yes, glib=no)
|
||||
if test "$glib" = no; then
|
||||
AC_MSG_ERROR(Cannot find GLib!)
|
||||
fi
|
||||
|
||||
COMMON_CFLAGS="$GLIB_CFLAGS"
|
||||
COMMON_LIBS="$GLIB_LIBS"
|
||||
COMMON_LIBS="$COMMON_LIBS -lgmodule-2.0"
|
||||
PKG_CHECK_MODULES([GOBJECT], [gobject-2.0], [], [AC_MSG_ERROR(Cannot find gobject-2.0!)])
|
||||
|
||||
COMMON_CFLAGS="$GLIB_CFLAGS $GOBJECT_CFLAGS -DG_DISABLE_SINGLE_INCLUDES"
|
||||
COMMON_LIBS="$GLIB_LIBS $GOBJECT_LIBS -lgmodule-2.0"
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** GTK **************************************************************
|
||||
@ -201,7 +222,7 @@ dnl *********************************************************************
|
||||
|
||||
# we might get undefined macro without this test
|
||||
if test "$gtkfe" = yes ; then
|
||||
AM_PATH_GTK_2_0(2.10.0, havegtk=yes, havegtk=no)
|
||||
AM_PATH_GTK_2_0(2.24.0, havegtk=yes, havegtk=no)
|
||||
|
||||
if test "$havegtk" = no; then
|
||||
gtkfe=no
|
||||
@ -213,8 +234,6 @@ fi
|
||||
|
||||
if test "$gtkfe" != yes; then
|
||||
gnome=no
|
||||
COMMON_LIBS="$GLIB_LIBS"
|
||||
COMMON_CFLAGS="$GLIB_CFLAGS"
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
@ -222,18 +241,17 @@ dnl ** GNOME ************************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
GUI_LIBS="$GUI_LIBS $GTK_LIBS"
|
||||
GUI_CFLAGS="$GUI_CFLAGS $GTK_CFLAGS"
|
||||
GUI_CFLAGS="$GUI_CFLAGS $GTK_CFLAGS -DG_DISABLE_SINGLE_INCLUDES -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_SINGLE_INCLUDES"
|
||||
|
||||
#if test "$gnome" = yes; then
|
||||
# AC_PATH_PROG(pkgconfigpath, pkg-config)
|
||||
# AC_MSG_CHECKING(Gnome2 compile flags)
|
||||
# GNOME_CFLAGS="`$pkgconfigpath libgnome-2.0 --cflags 2>/dev/null`"
|
||||
# GNOME_CFLAGS="`$PKG_CONFIG libgnome-2.0 --cflags 2>/dev/null`"
|
||||
# if test "_$GNOME_CFLAGS" = _ ; then
|
||||
# gnome=no
|
||||
# AC_MSG_RESULT([Gnome not found, building without it.])
|
||||
# else
|
||||
# GNOME_VER="`$pkgconfigpath libgnome-2.0 --modversion`"
|
||||
# GUI_LIBS="$GUI_LIBS `$pkgconfigpath libgnome-2.0 --libs`"
|
||||
# GNOME_VER="`$PKG_CONFIG libgnome-2.0 --modversion`"
|
||||
# GUI_LIBS="$GUI_LIBS `$PKG_CONFIG libgnome-2.0 --libs`"
|
||||
# GUI_CFLAGS="$GUI_CFLAGS $GNOME_CFLAGS"
|
||||
# AC_DEFINE(USE_GNOME)
|
||||
# AC_MSG_RESULT(ok)
|
||||
@ -241,21 +259,20 @@ GUI_CFLAGS="$GUI_CFLAGS $GTK_CFLAGS"
|
||||
#fi
|
||||
|
||||
# GConf
|
||||
if test "$gnome" != no ; then
|
||||
AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
|
||||
else
|
||||
GCONFTOOL=no
|
||||
fi
|
||||
#if test "$gnome" != no ; then
|
||||
# AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
|
||||
#else
|
||||
# GCONFTOOL=no
|
||||
#fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** XFT **************************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
if test "$xft" = yes; then
|
||||
AC_PATH_PROG(pkgconfigpath, pkg-config)
|
||||
if $pkgconfigpath xft --exists; then
|
||||
GUI_CFLAGS="$GUI_CFLAGS `$pkgconfigpath xft --cflags`"
|
||||
GUI_LIBS="$GUI_LIBS `$pkgconfigpath xft --libs`"
|
||||
if $PKG_CONFIG xft --exists; then
|
||||
GUI_CFLAGS="$GUI_CFLAGS `$PKG_CONFIG xft --cflags`"
|
||||
GUI_LIBS="$GUI_LIBS `$PKG_CONFIG xft --libs`"
|
||||
else
|
||||
xft=no
|
||||
oldCPPFLAGS=$CPPFLAGS
|
||||
@ -335,70 +352,29 @@ dnl ** PYTHON ***********************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
if test "x$python" != xno ; then
|
||||
if test "$python" = yes ; then
|
||||
# default
|
||||
python="python2"
|
||||
fi
|
||||
AC_PATH_PROG(pythonpath, $python)
|
||||
if test "_$pythonpath" = _ ; then
|
||||
AC_PATH_PROG(pythonpath, python)
|
||||
fi
|
||||
if test "_$pythonpath" = _ ; then
|
||||
python=no
|
||||
else
|
||||
AC_MSG_CHECKING(Python version)
|
||||
changequote(<<, >>)dnl
|
||||
PY_VER=`$pythonpath -c 'import distutils.sysconfig; print(distutils.sysconfig.get_config_vars("VERSION")[0]);'`
|
||||
PY_LIB=`$pythonpath -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(standard_lib=1));'`
|
||||
PY_INC=`$pythonpath -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_inc());'`
|
||||
PYPLAT_INC=`$pythonpath -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_inc(plat_specific=True));'`
|
||||
changequote([, ])dnl
|
||||
AC_MSG_RESULT($PY_VER)
|
||||
$pythonpath -c "import sys; float(sys.version[[:3]]) >= 2.2 and int(sys.version[[0]]) < 3 or sys.exit(1)"
|
||||
if test "$?" != "1"; then
|
||||
AC_MSG_CHECKING(Python compile flags)
|
||||
PY_PREFIX=`$pythonpath -c 'import sys; print(sys.prefix)'`
|
||||
PY_EXEC_PREFIX=`$pythonpath -c 'import sys; print(sys.exec_prefix)'`
|
||||
if test -f $PY_INC/Python.h || test -f $PYPLAT_INC/Python.h; then
|
||||
PY_LIBS="-L$PY_LIB/config -lpython$PY_VER -lpthread -lutil"
|
||||
PY_CFLAGS="-I$PY_INC -I$PYPLAT_INC"
|
||||
AC_MSG_RESULT(ok)
|
||||
else
|
||||
python=no
|
||||
AC_MSG_RESULT([Can't find Python.h])
|
||||
fi
|
||||
else
|
||||
echo "Python is too old or too new. Only 2.2-2.7 are supported."
|
||||
python=no
|
||||
fi
|
||||
fi
|
||||
case $python in
|
||||
dnl set python2 default here
|
||||
python2)
|
||||
PKG_CHECK_MODULES([PY], [python-2.7], [], [AC_MSG_ERROR(Cannot find python-2.7!)])
|
||||
PY_VER="`$PKG_CONFIG --modversion python-2.7`";;
|
||||
dnl set python3 default here
|
||||
python3)
|
||||
PKG_CHECK_MODULES([PY], [python-3.3], [], [AC_MSG_ERROR(Cannot find python-3.3!)])
|
||||
PY_VER="`$PKG_CONFIG --modversion python-3.3`";;
|
||||
dnl add broken versions here
|
||||
python2.5|python2.6|python3.1|python3.2)
|
||||
AC_MSG_ERROR(Unsupported Python version ${python}!);;
|
||||
python*)
|
||||
python="python-${python#python}" # stay posix compliant
|
||||
PKG_CHECK_MODULES([PY], [${python}], [], [AC_MSG_ERROR(Cannot find "${python}.pc"!)])
|
||||
PY_VER="`$PKG_CONFIG --modversion ${python}`";;
|
||||
*)
|
||||
AC_MSG_ERROR(Unsupported Python ${python}!)
|
||||
esac
|
||||
AC_MSG_CHECKING(Python version)
|
||||
AC_MSG_RESULT($PY_VER)
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** TCL **************************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
dnl AC_MSG_CHECKING(for location of tclConfig.sh)
|
||||
dnl dirs="$tcl /lib /usr/lib /usr/tcl/lib /usr/lib/tcl8.4 /usr/local/lib /usr/local/tcl-8.4/lib /usr/local/tcl/lib /opt/lib /usr/lib/tcl8.3"
|
||||
dnl found=0
|
||||
dnl if test "$tcl" != "no"; then
|
||||
dnl tcl=no
|
||||
dnl for try in $dirs; do
|
||||
dnl if test -f $try/tclConfig.sh; then
|
||||
dnl found=1
|
||||
dnl . $try/tclConfig.sh
|
||||
dnl TCL_LIBS="$TCL_LIB_SPEC $TCL_LIBS"
|
||||
dnl TCL_CFLAGS="-I${TCL_PREFIX}/include $TCL_INCLUDE_SPEC"
|
||||
dnl tcl=yes
|
||||
dnl AC_MSG_RESULT($try/tclConfig.sh)
|
||||
dnl break
|
||||
dnl fi
|
||||
dnl done
|
||||
dnl if test "$found" -eq 0 ; then
|
||||
dnl AC_MSG_RESULT([tclConfig.sh not found - use the --enable-tcl option])
|
||||
dnl fi
|
||||
dnl fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** IPv6 *************************************************************
|
||||
dnl *********************************************************************
|
||||
@ -431,11 +407,10 @@ dnl *********************************************************************
|
||||
|
||||
retry=no
|
||||
if test "$openssl" != no; then
|
||||
AC_PATH_PROG(pkgconfigpath, pkg-config)
|
||||
AC_MSG_CHECKING(for openssl through pkg-config)
|
||||
if $pkgconfigpath openssl --exists; then
|
||||
CPPFLAGS="$CPPFLAGS `$pkgconfigpath openssl --cflags`"
|
||||
LIBS="$LIBS `$pkgconfigpath openssl --libs`"
|
||||
if $PKG_CONFIG openssl --exists; then
|
||||
CPPFLAGS="$CPPFLAGS `$PKG_CONFIG openssl --cflags`"
|
||||
LIBS="$LIBS `$PKG_CONFIG openssl --libs`"
|
||||
AC_DEFINE(USE_OPENSSL)
|
||||
AC_MSG_RESULT(yes)
|
||||
openssl=yes
|
||||
@ -511,9 +486,8 @@ if test "$plugin" = yes; then
|
||||
fi
|
||||
if test "$have_dl" = yes; then
|
||||
AC_DEFINE(USE_PLUGIN)
|
||||
AC_PATH_PROG(pkgconfigpath, pkg-config)
|
||||
dnl we just need the -Wl,--export-dynamic, but not -lgmodule-2.0
|
||||
RDYNAMIC_FLAGS="`$pkgconfigpath gmodule-2.0 --libs | $sedpath 's/ -lgmodule-2.0//'`"
|
||||
RDYNAMIC_FLAGS="`$PKG_CONFIG gmodule-2.0 --libs | $sedpath 's/ -lgmodule-2.0//'`"
|
||||
LIBS="$LIBS $RDYNAMIC_FLAGS"
|
||||
if test "$LD" = ""; then
|
||||
VS="`ld --help | grep version-script 2> /dev/null`"
|
||||
@ -585,21 +559,6 @@ if test "$fishlim" != "no"; then
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** SASL *************************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
dnl if test "$sasl" != "no"; then
|
||||
dnl AC_MSG_CHECKING(for plugin interface used by SASL)
|
||||
dnl sasl=no
|
||||
dnl if test "$plugin" = yes; then
|
||||
dnl sasl=yes
|
||||
dnl AC_MSG_RESULT([yes])
|
||||
dnl else
|
||||
dnl AC_MSG_RESULT([plugins are disabled, use the --enable-plugin option for SASL])
|
||||
dnl fi
|
||||
dnl fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** SYSINFO **********************************************************
|
||||
dnl *********************************************************************
|
||||
@ -653,6 +612,21 @@ if test "x$libnotify" = "xyes" ; then
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** LIBCANBERRA ******************************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
if test "x$libcanberra" = "xyes" ; then
|
||||
PKG_CHECK_MODULES(LIBCANBERRA, libcanberra >= 0.22, [], [
|
||||
libcanberra=no
|
||||
])
|
||||
if test "$libcanberra" != "no" ; then
|
||||
COMMON_LIBS="$COMMON_LIBS $LIBCANBERRA_LIBS"
|
||||
COMMON_CFLAGS="$COMMON_CFLAGS $LIBCANBERRA_CFLAGS"
|
||||
AC_DEFINE(USE_LIBCANBERRA)
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** SPELL ************************************************************
|
||||
dnl *********************************************************************
|
||||
@ -684,7 +658,7 @@ if test "$spell" = "static" ; then
|
||||
PKG_CHECK_MODULES(LIBXML2, libxml-2.0 >= 2.0.0, [
|
||||
AC_DEFINE(HAVE_ISO_CODES)
|
||||
AC_DEFINE(USE_LIBSEXY)
|
||||
GUI_CFLAGS="$GUI_CFLAGS -I/usr/include/libxml2"
|
||||
GUI_CFLAGS="$GUI_CFLAGS $LIBXML2_CFLAGS"
|
||||
LIBS="$LIBS -lxml2"
|
||||
], [
|
||||
AC_MSG_ERROR(Cannot find libxml2!)
|
||||
@ -698,19 +672,19 @@ dnl *********************************************************************
|
||||
AM_CONDITIONAL(USE_OPENSSL, test "x$openssl" = "xyes")
|
||||
AM_CONDITIONAL(USE_LIBSEXY, test "x$spell" = "xstatic")
|
||||
AM_CONDITIONAL(USE_LIBNOTIFY, test "x$libnotify" = "xyes")
|
||||
AM_CONDITIONAL(USE_LIBCANBERRA, test "x$libcanberra" = "xyes")
|
||||
AM_CONDITIONAL(DO_TEXT, test "x$textfe" = "xyes")
|
||||
AM_CONDITIONAL(DO_GTK, test "x$gtkfe" = "xyes")
|
||||
AM_CONDITIONAL(DO_PERL, test "x$perl" = "xyes")
|
||||
AM_CONDITIONAL(DO_PYTHON, test "x$python" != "xno")
|
||||
dnl AM_CONDITIONAL(DO_TCL, test "x$tcl" = "xyes")
|
||||
AM_CONDITIONAL(DO_PLUGIN, test "x$plugin" = "xyes")
|
||||
AM_CONDITIONAL(DO_CHECKSUM, test "x$checksum" = "xyes")
|
||||
AM_CONDITIONAL(DO_DOAT, test "x$doat" = "xyes")
|
||||
AM_CONDITIONAL(DO_FISHLIM, test "x$fishlim" = "xyes")
|
||||
dnl AM_CONDITIONAL(DO_SASL, test "x$sasl" = "xyes")
|
||||
AM_CONDITIONAL(DO_SYSINFO, test "x$sysinfo" = "xyes")
|
||||
AM_CONDITIONAL(USE_DBUS, test "x$dbus" = "xyes")
|
||||
AM_CONDITIONAL(DO_GCONF, test "x$GCONFTOOL" != "xno")
|
||||
#AM_CONDITIONAL(DO_GCONF, test "x$GCONFTOOL" != "xno")
|
||||
AM_CONDITIONAL(WITH_TM, test "x$theme_manager" != "xno")
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** SOCKS5 ***********************************************************
|
||||
@ -750,8 +724,8 @@ dnl *********************************************************************
|
||||
if test "$shm" = yes; then
|
||||
oldl=$LIBS
|
||||
oldc=$CPPFLAGS
|
||||
LIBS="$LIBS `$pkgconfigpath --libs-only-L xft`"
|
||||
CPPFLAGS="$CPPFLAGS `$pkgconfigpath --cflags-only-I xft`"
|
||||
LIBS="$LIBS `$PKG_CONFIG --libs-only-L xft`"
|
||||
CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags-only-I xft`"
|
||||
shm=no
|
||||
AC_CHECK_LIB(Xext, XShmAttach, shm=yes)
|
||||
if test "$shm" = yes; then
|
||||
@ -765,7 +739,7 @@ if test "$shm" = yes; then
|
||||
|
||||
LIBS=$oldl
|
||||
if test "$shm" = yes; then
|
||||
GUI_LIBS="$GUI_LIBS `$pkgconfigpath --libs-only-L xft` -lX11 -lXext"
|
||||
GUI_LIBS="$GUI_LIBS `$PKG_CONFIG --libs-only-L xft` -lX11 -lXext"
|
||||
AC_DEFINE(USE_SHM)
|
||||
else
|
||||
CPPFLAGS=$oldc
|
||||
@ -807,13 +781,16 @@ if test "x$GCC" = "xyes"; then
|
||||
if test -z "`echo "$CFLAGS" | grep "\-Wall" 2> /dev/null`" ; then
|
||||
CFLAGS="$CFLAGS -Wall"
|
||||
fi
|
||||
if test "$system" = "Linux" -o "$system" = "FreeBSD"; then
|
||||
if test -z "`echo "$CFLAGS" | grep "\-pipe" 2> /dev/null`" ; then
|
||||
CFLAGS="$CFLAGS -pipe"
|
||||
dnl these flags might be unwanted
|
||||
if test x$minimalflags != xyes; then
|
||||
if test "$system" = "Linux" -o "$system" = "FreeBSD"; then
|
||||
if test -z "`echo "$CFLAGS" | grep "\-pipe" 2> /dev/null`" ; then
|
||||
CFLAGS="$CFLAGS -pipe"
|
||||
fi
|
||||
fi
|
||||
if test -z "`echo "$CFLAGS" | grep "\-g " 2> /dev/null`" ; then
|
||||
CFLAGS="$CFLAGS -g"
|
||||
fi
|
||||
fi
|
||||
if test -z "`echo "$CFLAGS" | grep "\-g " 2> /dev/null`" ; then
|
||||
CFLAGS="$CFLAGS -g"
|
||||
fi
|
||||
fi
|
||||
|
||||
@ -861,12 +838,34 @@ if test x$unsigned_char = xyes; then
|
||||
CFLAGS="$CFLAGS -funsigned-char"
|
||||
fi
|
||||
|
||||
dnl does this compiler support -Wno-unused-result ?
|
||||
AC_MSG_CHECKING([if gcc accepts -Wno-unused-result ])
|
||||
|
||||
safe_CFLAGS=$CFLAGS
|
||||
CFLAGS="-Wno-unused-result"
|
||||
|
||||
AC_TRY_COMPILE(, [
|
||||
int main () { return 0 ; }
|
||||
],
|
||||
[
|
||||
no_unused_result=yes
|
||||
AC_MSG_RESULT([yes])
|
||||
], [
|
||||
no_unused_result=no
|
||||
AC_MSG_RESULT([no])
|
||||
])
|
||||
CFLAGS=$safe_CFLAGS
|
||||
|
||||
if test x$no_unused_result = xyes; then
|
||||
CFLAGS="$CFLAGS -Wno-unused-result"
|
||||
fi
|
||||
|
||||
dnl *********************************************************************
|
||||
dnl ** FUNCTIONS/LIBS/CFLAGS ********************************************
|
||||
dnl *********************************************************************
|
||||
|
||||
AC_MSG_CHECKING(for modern sigaction)
|
||||
dnl libc5 on linux and FreeBSD 3.x doesn't have siginfo_t
|
||||
dnl libc5 on linux and FreeBSD 3.x doesn\'t have siginfo_t
|
||||
dnl and the sa_sigation field.
|
||||
AC_TRY_COMPILE(
|
||||
[#include <signal.h>],
|
||||
@ -885,7 +884,7 @@ if test "$gtkfe" != no -a "_$gdkpixbufcsourcepath" = _; then
|
||||
AC_MSG_ERROR(Cannot find gdk-pixbuf-csource: Install GTK+ 2.0!)
|
||||
fi
|
||||
|
||||
dnl if we don't have this, use g_snprintf instead
|
||||
dnl if we don\'t have this, use g_snprintf instead
|
||||
AC_CHECK_FUNCS(snprintf vsnprintf memrchr strtoull)
|
||||
|
||||
AC_CHECK_FUNC(gethostbyname, ,
|
||||
@ -933,11 +932,10 @@ AC_SUBST(PERL_CFLAGS)
|
||||
AC_SUBST(PERL_LDFLAGS)
|
||||
AC_SUBST(PY_CFLAGS)
|
||||
AC_SUBST(PY_LIBS)
|
||||
dnl AC_SUBST(TCL_LIBS)
|
||||
dnl AC_SUBST(TCL_CFLAGS)
|
||||
AC_SUBST(DBUS_CFLAGS)
|
||||
AC_SUBST(DBUS_LIBS)
|
||||
|
||||
m4_ifdef([PKG_INSTALLDIR], [PKG_INSTALLDIR], AC_SUBST([pkgconfigdir], ${libdir}/pkgconfig))
|
||||
|
||||
PLUGIN_INCLUDES='-I$(top_srcdir)/plugins'
|
||||
AC_SUBST(PLUGIN_INCLUDES)
|
||||
@ -948,14 +946,14 @@ test "x$exec_prefix" = xNONE && exec_prefix="$prefix"
|
||||
|
||||
AC_DEFINE_UNQUOTED(PREFIX, "${prefix}")
|
||||
|
||||
AS_AC_EXPAND(HEXCHATLIBDIR, "${libdir}/hexchat")
|
||||
AS_AC_EXPAND(HEXCHATLIBDIR, "${libdir}/hexchat/plugins")
|
||||
AC_DEFINE_UNQUOTED(HEXCHATLIBDIR, "$HEXCHATLIBDIR")
|
||||
|
||||
AS_AC_EXPAND(HEXCHATSHAREDIR, "$datadir")
|
||||
AC_DEFINE_UNQUOTED(HEXCHATSHAREDIR, "$HEXCHATSHAREDIR")
|
||||
|
||||
dnl for plugins/xxx/Makefile.am
|
||||
hexchatlibdir=${libdir}/hexchat
|
||||
hexchatlibdir=${libdir}/hexchat/plugins
|
||||
AC_SUBST(hexchatlibdir)
|
||||
|
||||
AC_CONFIG_FILES([
|
||||
@ -963,11 +961,15 @@ Makefile
|
||||
share/Makefile
|
||||
share/icons/Makefile
|
||||
share/misc/Makefile
|
||||
share/pkgconfig/Makefile
|
||||
share/pkgconfig/hexchat-plugin.pc
|
||||
src/Makefile
|
||||
src/common/Makefile
|
||||
src/common/dbus/Makefile
|
||||
src/fe-text/Makefile
|
||||
src/fe-gtk/Makefile
|
||||
src/htm/Makefile
|
||||
src/htm/thememan
|
||||
src/pixmaps/Makefile
|
||||
plugins/Makefile
|
||||
plugins/python/Makefile
|
||||
@ -980,8 +982,6 @@ intl/Makefile
|
||||
po/Makefile.in
|
||||
man/Makefile
|
||||
])
|
||||
dnl plugins/tcl/Makefile
|
||||
dnl plugins/sasl/Makefile
|
||||
|
||||
AC_OUTPUT
|
||||
|
||||
@ -990,6 +990,7 @@ echo HexChat $VERSION
|
||||
echo
|
||||
echo GTK+ interface ........ : $gtkfe
|
||||
echo Text interface ........ : $textfe
|
||||
echo Theme manager ......... : $theme_manager
|
||||
echo
|
||||
echo MMX tinting ........... : $mmx
|
||||
echo XShm tinting .......... : $shm
|
||||
@ -1001,6 +1002,7 @@ fi
|
||||
echo OpenSSL support ....... : $openssl
|
||||
echo D-Bus support ......... : $dbus
|
||||
echo libnotify support ..... : $libnotify
|
||||
echo libcanberra support ... : $libcanberra
|
||||
echo Spelling .............. : $spell
|
||||
echo Plugin interface ...... : $plugin
|
||||
echo NLS/gettext ........... : $USE_NLS
|
||||
@ -1009,13 +1011,11 @@ echo MS Proxy NTLM \(ISA\) ... : $have_ntlm
|
||||
echo libproxy support ...... : $libproxy
|
||||
echo
|
||||
echo Perl .................. : $perl
|
||||
echo Python ................ : $python
|
||||
dnl echo Tcl ................... : $tcl
|
||||
echo Python ................ : python-$PY_VER
|
||||
echo
|
||||
echo Checksum .............. : $checksum
|
||||
echo Do At ................. : $doat
|
||||
echo FiSHLiM ............... : $fishlim
|
||||
dnl echo SASL .................. : $sasl
|
||||
echo SysInfo ............... : $sysinfo
|
||||
echo
|
||||
echo The binary will be installed in $prefix/bin
|
||||
|
110
man/hexchat.1
110
man/hexchat.1
@ -1,55 +1,55 @@
|
||||
.TH HEXCHAT "1" "April 2013" "HexChat 2.9.5" "User Commands"
|
||||
.SH NAME
|
||||
HexChat \- manual page for HexChat 2.9.5
|
||||
.SH DESCRIPTION
|
||||
.SS "Usage:"
|
||||
.IP
|
||||
hexchat [OPTION...]
|
||||
.SS "Help Options:"
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Show help options
|
||||
.TP
|
||||
\fB\-\-help\-all\fR
|
||||
Show all help options
|
||||
.TP
|
||||
\fB\-\-help\-gtk\fR
|
||||
Show GTK+ Options
|
||||
.SS "Application Options:"
|
||||
.TP
|
||||
\fB\-a\fR, \fB\-\-no\-auto\fR
|
||||
Don't auto connect to servers
|
||||
.TP
|
||||
\fB\-d\fR, \fB\-\-cfgdir\fR=\fIPATH\fR
|
||||
Use a different config directory
|
||||
.TP
|
||||
\fB\-n\fR, \fB\-\-no\-plugins\fR
|
||||
Don't auto load any plugins
|
||||
.TP
|
||||
\fB\-p\fR, \fB\-\-plugindir\fR
|
||||
Show plugin auto\-load directory
|
||||
.TP
|
||||
\fB\-u\fR, \fB\-\-configdir\fR
|
||||
Show user config directory
|
||||
.TP
|
||||
\fB\-\-url\fR=\fIURL\fR
|
||||
Open an irc://server:port/channel URL
|
||||
.TP
|
||||
\fB\-c\fR, \fB\-\-command\fR=\fICOMMAND\fR
|
||||
Execute command:
|
||||
.TP
|
||||
\fB\-e\fR, \fB\-\-existing\fR
|
||||
Open URL or execute command in an existing HexChat
|
||||
.TP
|
||||
\fB\-\-minimize\fR=\fIlevel\fR
|
||||
Begin minimized. Level 0=Normal 1=Iconified 2=Tray
|
||||
.TP
|
||||
\fB\-v\fR, \fB\-\-version\fR
|
||||
Show version information
|
||||
.TP
|
||||
\fB\-\-display\fR=\fIDISPLAY\fR
|
||||
X display to use
|
||||
|
||||
.SH AUTHOR
|
||||
This manual page was written by Davide Puricelli <evo@debian.org> for the Debian GNU/Linux system (but
|
||||
may be used by others).
|
||||
.TH HEXCHAT "1" "April 2013" "HexChat 2.9.6" "User Commands"
|
||||
.SH NAME
|
||||
HexChat \- IRC Client
|
||||
.SH DESCRIPTION
|
||||
.SS "Usage:"
|
||||
.IP
|
||||
hexchat [OPTION...] URL
|
||||
.SS "Help Options:"
|
||||
.TP
|
||||
\fB\-h\fR, \fB\-\-help\fR
|
||||
Show help options
|
||||
.TP
|
||||
\fB\-\-help\-all\fR
|
||||
Show all help options
|
||||
.TP
|
||||
\fB\-\-help\-gtk\fR
|
||||
Show GTK+ Options
|
||||
.SS "Application Options:"
|
||||
.TP
|
||||
\fB\-a\fR, \fB\-\-no\-auto\fR
|
||||
Don't auto connect to servers
|
||||
.TP
|
||||
\fB\-d\fR, \fB\-\-cfgdir\fR=\fIPATH\fR
|
||||
Use a different config directory
|
||||
.TP
|
||||
\fB\-n\fR, \fB\-\-no\-plugins\fR
|
||||
Don't auto load any plugins
|
||||
.TP
|
||||
\fB\-p\fR, \fB\-\-plugindir\fR
|
||||
Show plugin auto\-load directory
|
||||
.TP
|
||||
\fB\-u\fR, \fB\-\-configdir\fR
|
||||
Show user config directory
|
||||
.TP
|
||||
\fB\-\-url\fR=\fIURL\fR
|
||||
Open an irc://server:port/channel?key URL
|
||||
.TP
|
||||
\fB\-c\fR, \fB\-\-command\fR=\fICOMMAND\fR
|
||||
Execute command:
|
||||
.TP
|
||||
\fB\-e\fR, \fB\-\-existing\fR
|
||||
Open URL or execute command in an existing HexChat
|
||||
.TP
|
||||
\fB\-\-minimize\fR=\fIlevel\fR
|
||||
Begin minimized. Level 0=Normal 1=Iconified 2=Tray
|
||||
.TP
|
||||
\fB\-v\fR, \fB\-\-version\fR
|
||||
Show version information
|
||||
.TP
|
||||
\fB\-\-display\fR=\fIDISPLAY\fR
|
||||
X display to use
|
||||
|
||||
.SH AUTHOR
|
||||
This manual page was written by Davide Puricelli <evo@debian.org> for the Debian GNU/Linux system (but
|
||||
may be used by others).
|
||||
|
@ -1,4 +1,4 @@
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = checksum.la
|
||||
checksum_la_SOURCES = checksum.c
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;CHECKSUM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -77,7 +79,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;CHECKSUM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;DNS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -77,7 +79,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;DNS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -1,4 +1,4 @@
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = doat.la
|
||||
doat_la_SOURCES = doat.c
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;DOAT_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -75,7 +77,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;DOAT_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -28,7 +28,7 @@
|
||||
static hexchat_plugin *ph; /* plugin handle */
|
||||
static char name[] = "Exec";
|
||||
static char desc[] = "Execute commands inside HexChat";
|
||||
static char version[] = "1.1";
|
||||
static char version[] = "1.2";
|
||||
|
||||
static int
|
||||
run_command (char *word[], char *word_eol[], void *userdata)
|
||||
@ -41,6 +41,10 @@ run_command (char *word[], char *word_eol[], void *userdata)
|
||||
time_t start;
|
||||
double timeElapsed;
|
||||
|
||||
char *token;
|
||||
char *context = NULL;
|
||||
int announce = 0;
|
||||
|
||||
HANDLE readPipe;
|
||||
HANDLE writePipe;
|
||||
STARTUPINFO sInfo;
|
||||
@ -59,9 +63,8 @@ run_command (char *word[], char *word_eol[], void *userdata)
|
||||
|
||||
if (!stricmp("-O", word[2]))
|
||||
{
|
||||
/*strcat (commandLine, word_eol[3]);*/
|
||||
hexchat_printf (ph, "Printing Exec output to others is not supported yet.\n");
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
strcat (commandLine, word_eol[3]);
|
||||
announce = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -90,7 +93,19 @@ run_command (char *word[], char *word_eol[], void *userdata)
|
||||
{
|
||||
/* avoid garbage */
|
||||
buffer[dwRead] = '\0';
|
||||
hexchat_printf (ph, "%s", buffer);
|
||||
|
||||
if (announce)
|
||||
{
|
||||
/* Say each line seperately, TODO: improve... */
|
||||
token = strtok_s (buffer, "\n", &context);
|
||||
while (token != NULL)
|
||||
{
|
||||
hexchat_commandf (ph, "SAY %s", token);
|
||||
token = strtok_s (NULL, "\n", &context);
|
||||
}
|
||||
}
|
||||
else
|
||||
hexchat_printf (ph, "%s", buffer);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -100,20 +115,25 @@ run_command (char *word[], char *word_eol[], void *userdata)
|
||||
}
|
||||
timeElapsed = difftime (time (0), start);
|
||||
}
|
||||
|
||||
/* display a newline to separate things */
|
||||
if (!announce)
|
||||
hexchat_printf (ph, "\n");
|
||||
|
||||
if (timeElapsed >= 10)
|
||||
{
|
||||
hexchat_printf (ph, "Command took too much time to run, execution aborted.\n");
|
||||
}
|
||||
|
||||
CloseHandle (readPipe);
|
||||
CloseHandle (pInfo.hProcess);
|
||||
CloseHandle (pInfo.hThread);
|
||||
}
|
||||
|
||||
/* display a newline to separate things */
|
||||
hexchat_printf (ph, "\n");
|
||||
|
||||
if (timeElapsed >= 10)
|
||||
else
|
||||
{
|
||||
hexchat_printf (ph, "Command took too much time to run, execution aborted.\n");
|
||||
hexchat_command (ph, "help exec");
|
||||
}
|
||||
|
||||
CloseHandle (readPipe);
|
||||
CloseHandle (pInfo.hProcess);
|
||||
CloseHandle (pInfo.hThread);
|
||||
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;EXEC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -75,7 +77,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;EXEC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -1,6 +1,6 @@
|
||||
EXTRA_DIST = INSTALL LICENSE README
|
||||
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = fishlim.la
|
||||
fishlim_la_SOURCES = fish.c irc.c keystore.c misc.c plugin_hexchat.c
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;FISHLIM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -77,7 +79,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;FISHLIM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;XTRAY_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -75,7 +77,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;XTRAY_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -131,11 +131,11 @@ int hexchat_plugin_init(hexchat_plugin *plugin_handle, char **plugin_name, char
|
||||
hexchat_hook_command(ph, "mpc", HEXCHAT_PRI_NORM, mpc_tell,"no help text", 0);
|
||||
hexchat_hook_command(ph, "mpc_themes", HEXCHAT_PRI_NORM, print_themes,"no help text", 0);
|
||||
hexchat_hook_command(ph, "mpc_reloadthemes", HEXCHAT_PRI_NORM, mpc_themeReload,"no help text", 0);
|
||||
hexchat_command (ph, "MENU -ietc\\music.png ADD \"Window/Display Current Song (MPC)\" \"MPC\"");
|
||||
hexchat_command (ph, "MENU -ishare\\music.png ADD \"Window/Display Current Song (MPC)\" \"MPC\"");
|
||||
|
||||
themeInit();
|
||||
loadThemes();
|
||||
hexchat_printf(ph, "%s %s plugin loaded\n",*plugin_name, VERSION);
|
||||
hexchat_printf(ph, "%s plugin loaded\n", *plugin_name);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;MPCINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -75,7 +77,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;MPCINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -2,7 +2,7 @@
|
||||
EXTRA_DIST=alt_completion.pl generate_header lib/Xchat.pm lib/Xchat/Embed.pm lib/Xchat/List/Network.pm \
|
||||
lib/Xchat/List/Network/Entry.pm lib/Xchat/List/Network/AutoJoin.pm lib/IRC.pm
|
||||
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = perl.la
|
||||
perl_la_SOURCES = perl.c
|
||||
|
@ -10,28 +10,26 @@ use overload
|
||||
|
||||
sub new {
|
||||
my $class = shift;
|
||||
my $line = shift;
|
||||
|
||||
my @autojoins;
|
||||
|
||||
if ( $line ) {
|
||||
my ( $channels, $keys ) = split / /, $line, 2;
|
||||
my @channels = split /,/, $channels;
|
||||
my @keys = split /,/, ($keys || '');
|
||||
|
||||
for my $channel ( @channels ) {
|
||||
my $key = shift @keys;
|
||||
$key = '' unless defined $key;
|
||||
|
||||
push @autojoins, {
|
||||
channel => $channel,
|
||||
key => $key,
|
||||
};
|
||||
}
|
||||
}
|
||||
return bless \@autojoins, $class;
|
||||
}
|
||||
|
||||
sub add {
|
||||
my $self = shift;
|
||||
|
||||
my $line = shift;
|
||||
|
||||
my ( $channel, $key ) = split /,/, $line, 2;
|
||||
$key = $key || '';
|
||||
|
||||
push @$self, {
|
||||
channel => $channel,
|
||||
key => $key,
|
||||
};
|
||||
}
|
||||
|
||||
sub channels {
|
||||
my $self = shift;
|
||||
|
||||
|
@ -39,6 +39,8 @@ sub parse {
|
||||
my @fields = split /\n/, $data;
|
||||
chomp @fields;
|
||||
|
||||
$entry->{ autojoins } = Xchat::List::Network::AutoJoin->new();
|
||||
|
||||
for my $field ( @fields ) {
|
||||
SWITCH: for ( $field ) {
|
||||
/^($letter_key_re)=(.*)/ && do {
|
||||
@ -47,8 +49,7 @@ sub parse {
|
||||
};
|
||||
|
||||
/^J.(.*)/ && do {
|
||||
$entry->{ autojoins } =
|
||||
Xchat::List::Network::AutoJoin->new( $1 );
|
||||
$entry->{ autojoins }->add( $1 );
|
||||
};
|
||||
|
||||
/^F.(.*)/ && do {
|
||||
|
@ -296,7 +296,7 @@ list_item_to_sv ( hexchat_list *list, const char *const *fields )
|
||||
default:
|
||||
field_value = &PL_sv_undef;
|
||||
}
|
||||
hv_store (hash, field_name, name_len, field_value, 0);
|
||||
(void)hv_store (hash, field_name, name_len, field_value, 0);
|
||||
field_index++;
|
||||
}
|
||||
return sv_2mortal (newRV_noinc ((SV *) hash));
|
||||
@ -1520,7 +1520,7 @@ perl_command_unload (char *word[], char *word_eol[], void *userdata)
|
||||
}
|
||||
|
||||
static int
|
||||
perl_command_reload (char *word[], char *word_eol[], void *userdata)
|
||||
perl_command_reload (char *word[], char *word_eol[], void *eat)
|
||||
{
|
||||
char *file = get_filename (word, word_eol);
|
||||
|
||||
@ -1529,7 +1529,10 @@ perl_command_reload (char *word[], char *word_eol[], void *userdata)
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
}
|
||||
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
if (eat)
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
else
|
||||
return HEXCHAT_EAT_NONE;
|
||||
}
|
||||
|
||||
void
|
||||
@ -1570,7 +1573,7 @@ hexchat_plugin_init (hexchat_plugin * plugin_handle, char **plugin_name,
|
||||
hexchat_hook_command (ph, "reload", HEXCHAT_PRI_NORM, perl_command_reload, 0,
|
||||
0);
|
||||
hexchat_hook_command (ph, "pl_reload", HEXCHAT_PRI_NORM, perl_command_reload, 0,
|
||||
0);
|
||||
(int*)1);
|
||||
hexchat_hook_command (ph, "unloadall", HEXCHAT_PRI_NORM,
|
||||
perl_command_unloadall, 0, 0);
|
||||
hexchat_hook_command (ph, "reloadall", HEXCHAT_PRI_NORM,
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -42,13 +45,13 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(Perl518Output)</TargetName>
|
||||
<TargetName>$(PerlOutput)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(Perl518Output)</TargetName>
|
||||
<TargetName>$(PerlOutput)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
@ -56,11 +59,10 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL518_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Perl518Path)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>$(PerlPath)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -69,15 +71,15 @@
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>$(Perl518Lib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>$(PerlLib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
|
||||
<DelayLoadDLLs>$(Perl518Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
<DelayLoadDLLs>$(PerlLib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>"$(GendefPath)\gendef" "$(Perl518Path)\bin\$(Perl518Lib).dll"
|
||||
move $(Perl518Lib).def "$(IntDir)"
|
||||
lib /nologo /machine:x86 "/def:$(IntDir)$(Perl518Lib).def" "/out:$(OutDir)\$(Perl518Lib).lib"
|
||||
"$(Perl518Path)\bin\perl.exe" generate_header
|
||||
<Command>"$(GendefPath)\gendef" "$(PerlPath)\bin\$(PerlLib).dll"
|
||||
move $(PerlLib).def "$(IntDir)"
|
||||
lib /nologo /machine:x86 "/def:$(IntDir)$(PerlLib).def" "/out:$(OutDir)\$(PerlLib).lib"
|
||||
"$(PerlPath)\bin\perl.exe" generate_header
|
||||
move irc.pm.h "$(IntDir)"
|
||||
move xchat.pm.h "$(IntDir)"</Command>
|
||||
</PreBuildEvent>
|
||||
@ -86,11 +88,10 @@ move xchat.pm.h "$(IntDir)"</Command>
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;PERL518_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Perl518Path)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>$(PerlPath)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -99,15 +100,15 @@ move xchat.pm.h "$(IntDir)"</Command>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>$(Perl518Lib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>$(PerlLib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
|
||||
<DelayLoadDLLs>$(Perl518Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
<DelayLoadDLLs>$(PerlLib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>"$(GendefPath)\gendef" "$(Perl518Path)\bin\$(Perl518Lib).dll"
|
||||
move $(Perl518Lib).def "$(IntDir)"
|
||||
lib /nologo /machine:x64 "/def:$(IntDir)$(Perl518Lib).def" "/out:$(OutDir)\$(Perl518Lib).lib"
|
||||
"$(Perl518Path)\bin\perl.exe" generate_header
|
||||
<Command>"$(GendefPath)\gendef" "$(PerlPath)\bin\$(PerlLib).dll"
|
||||
move $(PerlLib).def "$(IntDir)"
|
||||
lib /nologo /machine:x64 "/def:$(IntDir)$(PerlLib).def" "/out:$(OutDir)\$(PerlLib).lib"
|
||||
"$(PerlPath)\bin\perl.exe" generate_header
|
||||
move irc.pm.h "$(IntDir)"
|
||||
move xchat.pm.h "$(IntDir)"</Command>
|
||||
</PreBuildEvent>
|
@ -1,6 +1,6 @@
|
||||
EXTRA_DIST =
|
||||
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = python.la
|
||||
python_la_SOURCES = python.c
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -13,7 +16,7 @@
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{19C52A0A-A790-409E-A28A-9745FF990F5C}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>python</RootNamespace>
|
||||
<RootNamespace>python2</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
@ -42,13 +45,13 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(PythonOutput)</TargetName>
|
||||
<TargetName>$(Python2Output)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(PythonOutput)</TargetName>
|
||||
<TargetName>$(Python2Output)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
@ -56,11 +59,10 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(PythonPath)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(Python2Path)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -69,19 +71,18 @@
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ModuleDefinitionFile>python.def</ModuleDefinitionFile>
|
||||
<AdditionalDependencies>"$(PythonLib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(PythonPath)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>"$(Python2Lib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(Python2Path)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(PythonPath)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(Python2Path)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -90,8 +91,8 @@
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ModuleDefinitionFile>python.def</ModuleDefinitionFile>
|
||||
<AdditionalDependencies>"$(PythonLib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(PythonPath)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>"$(Python2Lib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(Python2Path)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -11,9 +14,9 @@
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{58654438-F674-42F7-88FA-73EF90AD80B1}</ProjectGuid>
|
||||
<ProjectGuid>{C2321A03-0BA7-45B3-8740-ABD82B36B0BF}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>perl516</RootNamespace>
|
||||
<RootNamespace>python3</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
@ -42,13 +45,13 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(Perl516Output)</TargetName>
|
||||
<TargetName>$(Python3Output)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>$(Perl516Output)</TargetName>
|
||||
<TargetName>$(Python3Output)</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
@ -56,11 +59,10 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL516_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Perl516Path)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(Python3Path)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -68,29 +70,19 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>$(Perl516Lib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
|
||||
<DelayLoadDLLs>$(Perl516Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
<ModuleDefinitionFile>python.def</ModuleDefinitionFile>
|
||||
<AdditionalDependencies>"$(Python3Lib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(Python3Path)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>"$(GendefPath)\gendef" "$(Perl516Path)\bin\$(Perl516Lib).dll"
|
||||
move $(Perl516Lib).def "$(IntDir)"
|
||||
lib /nologo /machine:x86 "/def:$(IntDir)$(Perl516Lib).def" "/out:$(OutDir)\$(Perl516Lib).lib"
|
||||
"$(Perl516Path)\bin\perl.exe" generate_header
|
||||
move irc.pm.h "$(IntDir)"
|
||||
move xchat.pm.h "$(IntDir)"</Command>
|
||||
</PreBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;PERL516_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Perl516Path)\lib\CORE;$(IntDir);..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(Glib);$(Python3Path)\include;..\..\src\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
@ -98,25 +90,16 @@ move xchat.pm.h "$(IntDir)"</Command>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>$(Perl516Lib).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
|
||||
<DelayLoadDLLs>$(Perl516Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
|
||||
<ModuleDefinitionFile>python.def</ModuleDefinitionFile>
|
||||
<AdditionalDependencies>"$(Python3Lib).lib";$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(Python3Path)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>"$(GendefPath)\gendef" "$(Perl516Path)\bin\$(Perl516Lib).dll"
|
||||
move $(Perl516Lib).def "$(IntDir)"
|
||||
lib /nologo /machine:x64 "/def:$(IntDir)$(Perl516Lib).def" "/out:$(OutDir)\$(Perl516Lib).lib"
|
||||
"$(Perl516Path)\bin\perl.exe" generate_header
|
||||
move irc.pm.h "$(IntDir)"
|
||||
move xchat.pm.h "$(IntDir)"</Command>
|
||||
</PreBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<None Include="perl.def" />
|
||||
<None Include="python.def" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="perl.c" />
|
||||
<ClCompile Include="python.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
@ -2,22 +2,20 @@
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
<UniqueIdentifier>{f4eaf231-f095-42d3-8427-b2b6006cacb1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files">
|
||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
|
||||
<UniqueIdentifier>{0166c0f9-7968-4a09-9ef5-a5179c7746eb}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="perl.def">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="perl.c">
|
||||
<ClCompile Include="python.c">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="python.def">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
</Project>
|
@ -1,4 +1,4 @@
|
||||
libdir = $(hexchatlibdir)/plugins
|
||||
libdir = $(hexchatlibdir)
|
||||
|
||||
lib_LTLIBRARIES = sysinfo.la
|
||||
sysinfo_la_SOURCES = hwmon.c match.c parse.c pci.c xsys.c
|
||||
|
@ -34,6 +34,7 @@ int hwmon_chip_present()
|
||||
return 0;
|
||||
}
|
||||
|
||||
#if 0
|
||||
void get_hwmon_chip_name(char *name)
|
||||
{
|
||||
char *position, buffer[bsize];
|
||||
@ -47,6 +48,7 @@ void get_hwmon_chip_name(char *name)
|
||||
fclose(fp);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void get_hwmon_temp(unsigned int *value, unsigned int *sensor)
|
||||
{
|
||||
|
@ -65,14 +65,31 @@ char *pretty_freespace(const char *desc, unsigned long long *free_k, unsigned lo
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
void remove_leading_whitespace(char *buffer)
|
||||
{
|
||||
char *pos;
|
||||
while((pos = memchr(buffer, 0x20, 1)))
|
||||
char *buffer2 = NULL;
|
||||
int i = 0, j = 0, ews = 0;
|
||||
|
||||
buffer2 = (char*)malloc(strlen(buffer) * sizeof(char));
|
||||
if (buffer2 == NULL)
|
||||
return;
|
||||
|
||||
memset (buffer2, (char)0, strlen(buffer));
|
||||
while (i < strlen(buffer))
|
||||
{
|
||||
pos += 1;
|
||||
strcpy(buffer, pos);
|
||||
/* count tabs, spaces as whitespace. */
|
||||
if (!(buffer[i] == (char)32 || buffer[i] == (char)9) || ews == 1)
|
||||
{
|
||||
ews = 1;
|
||||
buffer2[j] = buffer[i];
|
||||
j++;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
memset (buffer, (char)0, strlen(buffer));
|
||||
strcpy (buffer, buffer2);
|
||||
free (buffer2);
|
||||
}
|
||||
|
||||
char *decruft_filename(char *buffer)
|
||||
|
@ -378,22 +378,9 @@ int xs_parse_distro(char *name)
|
||||
{
|
||||
FILE *fp = NULL;
|
||||
char buffer[bsize], *pos = NULL;
|
||||
|
||||
if((fp = fopen("/etc/lsb-release", "r")) != NULL)
|
||||
{
|
||||
char id[bsize], codename[bsize], release[bsize];
|
||||
strcpy(id, "?");
|
||||
strcpy(codename, "?");
|
||||
strcpy(release, "?");
|
||||
while(fgets(buffer, bsize, fp) != NULL)
|
||||
{
|
||||
find_match_char(buffer, "DISTRIB_ID", id);
|
||||
find_match_char(buffer, "DISTRIB_CODENAME", codename);
|
||||
find_match_char(buffer, "DISTRIB_RELEASE", release);
|
||||
}
|
||||
snprintf(buffer, bsize, "%s \"%s\" %s", id, codename, release);
|
||||
}
|
||||
else if((fp = fopen("/etc/make.conf", "r")) != NULL)
|
||||
|
||||
if((fp = fopen("/etc/portage/make.conf", "r")) != NULL ||
|
||||
(fp = fopen("/etc/make.conf", "r")) != NULL)
|
||||
{
|
||||
char keywords[bsize];
|
||||
while(fgets(buffer, bsize, fp) != NULL)
|
||||
@ -403,7 +390,7 @@ int xs_parse_distro(char *name)
|
||||
snprintf(buffer, bsize, "Gentoo Linux (stable)");
|
||||
else
|
||||
snprintf(buffer, bsize, "Gentoo Linux %s", keywords);
|
||||
}
|
||||
}
|
||||
else if((fp = fopen("/etc/redhat-release", "r")) != NULL)
|
||||
fgets(buffer, bsize, fp);
|
||||
else if((fp = fopen("/etc/mageia-release", "r")) != NULL)
|
||||
@ -424,6 +411,20 @@ int xs_parse_distro(char *name)
|
||||
fgets(buffer, bsize, fp);
|
||||
else if((fp = fopen("/etc/arch-release", "r")) != NULL)
|
||||
snprintf(buffer, bsize, "ArchLinux");
|
||||
else if((fp = fopen("/etc/lsb-release", "r")) != NULL)
|
||||
{
|
||||
char id[bsize], codename[bsize], release[bsize];
|
||||
strcpy(id, "?");
|
||||
strcpy(codename, "?");
|
||||
strcpy(release, "?");
|
||||
while(fgets(buffer, bsize, fp) != NULL)
|
||||
{
|
||||
find_match_char(buffer, "DISTRIB_ID", id);
|
||||
find_match_char(buffer, "DISTRIB_CODENAME", codename);
|
||||
find_match_char(buffer, "DISTRIB_RELEASE", release);
|
||||
}
|
||||
snprintf(buffer, bsize, "%s \"%s\" %s", id, codename, release);
|
||||
}
|
||||
else
|
||||
snprintf(buffer, bsize, "Unknown Distro");
|
||||
if(fp != NULL) fclose(fp);
|
||||
@ -438,8 +439,10 @@ int xs_parse_hwmon_chip(char *chip)
|
||||
{
|
||||
if (!hwmon_chip_present())
|
||||
return 1;
|
||||
#if 0
|
||||
else
|
||||
get_hwmon_chip_name(chip);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -31,6 +31,7 @@ static hexchat_plugin *ph; /* plugin handle */
|
||||
static char name[] = "SysInfo";
|
||||
static char desc[] = "Display info about your hardware and OS";
|
||||
static char version[] = "1.1";
|
||||
static char helptext[] = "USAGE: /sysinfo - Sends info about your hardware and OS to current channel.";
|
||||
static int firstRun;
|
||||
static char *wmiOs;
|
||||
static char *wmiCpu;
|
||||
@ -397,8 +398,8 @@ hexchat_plugin_init (hexchat_plugin *plugin_handle, char **plugin_name, char **p
|
||||
|
||||
firstRun = 1;
|
||||
|
||||
hexchat_hook_command (ph, "SYSINFO", HEXCHAT_PRI_NORM, printInfo, NULL, NULL);
|
||||
hexchat_command (ph, "MENU -ietc\\system.png ADD \"Window/Display System Info\" \"SYSINFO\"");
|
||||
hexchat_hook_command (ph, "SYSINFO", HEXCHAT_PRI_NORM, printInfo, helptext, NULL);
|
||||
hexchat_command (ph, "MENU -ishare\\system.png ADD \"Window/Send System Info\" \"SYSINFO\"");
|
||||
|
||||
hexchat_printf (ph, "%s plugin loaded\n", name);
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;SYSINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -78,7 +80,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;SYSINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -35,6 +35,7 @@
|
||||
|
||||
#define DEFAULT_FORMAT "%B%1:%B %2 **"
|
||||
#define DEFAULT_PERCENT 1
|
||||
#define DEFAULT_ANNOUNCE 1
|
||||
#define DEFAULT_PCIIDS "/usr/share/hwdata/pci.ids"
|
||||
|
||||
static hexchat_plugin *ph; /* plugin handle */
|
||||
@ -43,7 +44,7 @@ static int error_printed = 0; /* semaphore, make sure not to print the same erro
|
||||
static char name[] = "SysInfo";
|
||||
static char desc[] = "Display info about your hardware and OS";
|
||||
static char version[] = "3.0";
|
||||
static char sysinfo_help[] = "SysInfo Usage:\n /SYSINFO [OS|DISTRO|CPU|RAM|DISK|VGA|SOUND|ETHERNET|UPTIME], print various details about your system or print a summary without arguments\n /SYSINFO LIST, print current settings\n /SYSINFO SET <variable>, update given setting\n /SYSINFO RESET, reset settings to defaults\n /NETDATA <iface>, show transmitted data on given interface\n /NETSTREAM <iface>, show current bandwidth on given interface\n";
|
||||
static char sysinfo_help[] = "SysInfo Usage:\n /SYSINFO [-e|-o] [OS|DISTRO|CPU|RAM|DISK|VGA|SOUND|ETHERNET|UPTIME], print various details about your system or print a summary without arguments\n /SYSINFO LIST, print current settings\n /SYSINFO SET <variable>, update given setting\n /SYSINFO RESET, reset settings to defaults\n /NETDATA <iface>, show transmitted data on given interface\n /NETSTREAM <iface>, show current bandwidth on given interface\n";
|
||||
|
||||
void
|
||||
sysinfo_get_pciids (char* dest)
|
||||
@ -57,6 +58,12 @@ sysinfo_get_percent ()
|
||||
return hexchat_pluginpref_get_int (ph, "percent");
|
||||
}
|
||||
|
||||
int
|
||||
sysinfo_get_announce ()
|
||||
{
|
||||
return hexchat_pluginpref_get_int (ph, "announce");
|
||||
}
|
||||
|
||||
void
|
||||
sysinfo_print_error (const char* msg)
|
||||
{
|
||||
@ -705,13 +712,15 @@ reset_settings ()
|
||||
hexchat_pluginpref_set_str (ph, "pciids", DEFAULT_PCIIDS);
|
||||
hexchat_pluginpref_set_str (ph, "format", DEFAULT_FORMAT);
|
||||
hexchat_pluginpref_set_int (ph, "percent", DEFAULT_PERCENT);
|
||||
hexchat_pluginpref_set_int (ph, "announce", DEFAULT_ANNOUNCE);
|
||||
}
|
||||
|
||||
static int
|
||||
sysinfo_cb (char *word[], char *word_eol[], void *userdata)
|
||||
{
|
||||
error_printed = 0;
|
||||
int announce = 0;
|
||||
int announce = sysinfo_get_announce ();
|
||||
int offset = 0;
|
||||
int buffer;
|
||||
char format[bsize];
|
||||
|
||||
@ -721,36 +730,49 @@ sysinfo_cb (char *word[], char *word_eol[], void *userdata)
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
|
||||
if (hexchat_list_int (ph, NULL, "type") >= 2)
|
||||
/* Cannot send to server tab */
|
||||
if (hexchat_list_int (ph, NULL, "type") == 1)
|
||||
{
|
||||
announce = 1;
|
||||
announce = 0;
|
||||
}
|
||||
|
||||
if (!g_ascii_strcasecmp ("HELP", word[2]))
|
||||
/* Allow overriding global announce setting */
|
||||
if (!strcmp ("-e", word[2]))
|
||||
{
|
||||
announce = 0;
|
||||
offset++;
|
||||
}
|
||||
else if (!strcmp ("-o", word[2]))
|
||||
{
|
||||
announce = 1;
|
||||
offset++;
|
||||
}
|
||||
|
||||
if (!g_ascii_strcasecmp ("HELP", word[2+offset]))
|
||||
{
|
||||
hexchat_printf (ph, sysinfo_help);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("LIST", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("LIST", word[2+offset]))
|
||||
{
|
||||
list_settings ();
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("SET", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("SET", word[2+offset]))
|
||||
{
|
||||
if (!g_ascii_strcasecmp ("", word_eol[4]))
|
||||
if (!g_ascii_strcasecmp ("", word_eol[4+offset]))
|
||||
{
|
||||
hexchat_printf (ph, "%s\tEnter a value!\n", name);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
if (!g_ascii_strcasecmp ("format", word[3]))
|
||||
if (!g_ascii_strcasecmp ("format", word[3+offset]))
|
||||
{
|
||||
hexchat_pluginpref_set_str (ph, "format", word_eol[4]);
|
||||
hexchat_printf (ph, "%s\tformat is set to: %s\n", name, word_eol[4]);
|
||||
hexchat_pluginpref_set_str (ph, "format", word_eol[4+offset]);
|
||||
hexchat_printf (ph, "%s\tformat is set to: %s\n", name, word_eol[4+offset]);
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("percent", word[3]))
|
||||
else if (!g_ascii_strcasecmp ("percent", word[3+offset]))
|
||||
{
|
||||
buffer = atoi (word[4]); /* don't use word_eol, numbers must not contain spaces */
|
||||
buffer = atoi (word[4+offset]); /* don't use word_eol, numbers must not contain spaces */
|
||||
|
||||
if (buffer > 0 && buffer < INT_MAX)
|
||||
{
|
||||
@ -762,10 +784,25 @@ sysinfo_cb (char *word[], char *word_eol[], void *userdata)
|
||||
hexchat_printf (ph, "%s\tInvalid input!\n", name);
|
||||
}
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("pciids", word[3]))
|
||||
else if (!g_ascii_strcasecmp ("announce", word[3+offset]))
|
||||
{
|
||||
hexchat_pluginpref_set_str (ph, "pciids", word_eol[4]);
|
||||
hexchat_printf (ph, "%s\tpciids is set to: %s\n", name, word_eol[4]);
|
||||
buffer = atoi (word[4+offset]); /* don't use word_eol, numbers must not contain spaces */
|
||||
|
||||
if (buffer > 0)
|
||||
{
|
||||
hexchat_pluginpref_set_int (ph, "announce", 1);
|
||||
hexchat_printf (ph, "%s\tannounce is set to: On\n", name);
|
||||
}
|
||||
else
|
||||
{
|
||||
hexchat_pluginpref_set_int (ph, "announce", 0);
|
||||
hexchat_printf (ph, "%s\tannounce is set to: Off\n", name);
|
||||
}
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("pciids", word[3+offset]))
|
||||
{
|
||||
hexchat_pluginpref_set_str (ph, "pciids", word_eol[4+offset]);
|
||||
hexchat_printf (ph, "%s\tpciids is set to: %s\n", name, word_eol[4+offset]);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -775,58 +812,58 @@ sysinfo_cb (char *word[], char *word_eol[], void *userdata)
|
||||
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("RESET", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("RESET", word[2+offset]))
|
||||
{
|
||||
reset_settings ();
|
||||
hexchat_printf (ph, "%s\tSettings have been restored to defaults.\n", name);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("OS", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("OS", word[2+offset]))
|
||||
{
|
||||
print_os (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("DISTRO", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("DISTRO", word[2+offset]))
|
||||
{
|
||||
print_distro (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("CPU", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("CPU", word[2+offset]))
|
||||
{
|
||||
print_cpu (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("RAM", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("RAM", word[2+offset]))
|
||||
{
|
||||
print_ram (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("DISK", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("DISK", word[2+offset]))
|
||||
{
|
||||
print_disk (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("VGA", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("VGA", word[2+offset]))
|
||||
{
|
||||
print_vga (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("SOUND", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("SOUND", word[2+offset]))
|
||||
{
|
||||
print_sound (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("ETHERNET", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("ETHERNET", word[2+offset]))
|
||||
{
|
||||
print_ethernet (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("UPTIME", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("UPTIME", word[2+offset]))
|
||||
{
|
||||
print_uptime (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
}
|
||||
else if (!g_ascii_strcasecmp ("", word[2]))
|
||||
else if (!g_ascii_strcasecmp ("", word[2+offset]))
|
||||
{
|
||||
print_summary (announce, format);
|
||||
return HEXCHAT_EAT_ALL;
|
||||
@ -867,7 +904,12 @@ hexchat_plugin_init (hexchat_plugin *plugin_handle, char **plugin_name, char **p
|
||||
hexchat_pluginpref_set_int (ph, "percent", DEFAULT_PERCENT);
|
||||
}
|
||||
|
||||
hexchat_command (ph, "MENU ADD \"Window/Display System Info\" \"SYSINFO\"");
|
||||
if (hexchat_pluginpref_get_int (ph, "announce") == -1)
|
||||
{
|
||||
hexchat_pluginpref_set_int (ph, "announce", DEFAULT_ANNOUNCE);
|
||||
}
|
||||
|
||||
hexchat_command (ph, "MENU ADD \"Window/Send System Info\" \"SYSINFO\"");
|
||||
hexchat_printf (ph, "%s plugin loaded\n", name);
|
||||
return 1;
|
||||
}
|
||||
|
@ -27,74 +27,19 @@
|
||||
|
||||
#include "hexchat-plugin.h"
|
||||
|
||||
#define DEFAULT_DELAY 10 /* 10 seconds */
|
||||
#define DEFAULT_DELAY 30 /* 30 seconds */
|
||||
#define DEFAULT_FREQ 360 /* 6 hours */
|
||||
#define DOWNLOAD_URL "http://dl.hexchat.net/hexchat"
|
||||
|
||||
static hexchat_plugin *ph; /* plugin handle */
|
||||
static char name[] = "Update Checker";
|
||||
static char desc[] = "Check for HexChat updates automatically";
|
||||
static char version[] = "4.0";
|
||||
static const char upd_help[] = "Update Checker Usage:\n /UPDCHK, check for HexChat updates\n /UPDCHK SET delay|freq, set startup delay or check frequency\n";
|
||||
static int legacy_os = 0;
|
||||
|
||||
static char*
|
||||
check_version ()
|
||||
{
|
||||
#if 0
|
||||
HINTERNET hINet, hFile;
|
||||
hINet = InternetOpen ("Update Checker", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
|
||||
|
||||
if (!hINet)
|
||||
{
|
||||
return "Unknown";
|
||||
}
|
||||
|
||||
hFile = InternetOpenUrl (hINet,
|
||||
"https://raw.github.com/hexchat/hexchat/master/win32/version.txt",
|
||||
NULL,
|
||||
0,
|
||||
INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD,
|
||||
0);
|
||||
if (hFile)
|
||||
{
|
||||
static char buffer[1024];
|
||||
DWORD dwRead;
|
||||
while (InternetReadFile (hFile, buffer, 1023, &dwRead))
|
||||
{
|
||||
if (dwRead == 0)
|
||||
{
|
||||
break;
|
||||
}
|
||||
buffer[dwRead] = 0;
|
||||
}
|
||||
|
||||
InternetCloseHandle (hFile);
|
||||
InternetCloseHandle (hINet);
|
||||
if (strlen (buffer) == 5)
|
||||
return buffer;
|
||||
else
|
||||
return "Unknown";
|
||||
}
|
||||
|
||||
InternetCloseHandle (hINet);
|
||||
return "Unknown";
|
||||
#endif
|
||||
|
||||
/* Google Code's messing up with requests, use HTTP/1.0 as suggested. More info:
|
||||
|
||||
http://code.google.com/p/support/issues/detail?id=6095
|
||||
|
||||
Of course it would be still too simple, coz IE will override settings, so
|
||||
you have to disable HTTP/1.1 manually and globally. More info:
|
||||
|
||||
http://support.microsoft.com/kb/258425
|
||||
|
||||
So this code's basically useless since disabling HTTP/1.1 will work with the
|
||||
above code too.
|
||||
|
||||
Update: a Connection: close header seems to disable chunked encoding.
|
||||
*/
|
||||
|
||||
HINTERNET hOpen, hConnect, hResource;
|
||||
|
||||
hOpen = InternetOpen (TEXT ("Update Checker"),
|
||||
@ -121,30 +66,14 @@ check_version ()
|
||||
return "Unknown";
|
||||
}
|
||||
|
||||
if (legacy_os)
|
||||
{
|
||||
hResource = HttpOpenRequest (hConnect,
|
||||
TEXT ("GET"),
|
||||
TEXT ("/hexchat/hexchat/master/win32/version-xp.txt"),
|
||||
TEXT ("HTTP/1.0"),
|
||||
NULL,
|
||||
NULL,
|
||||
INTERNET_FLAG_SECURE | INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_AUTH,
|
||||
0);
|
||||
}
|
||||
else
|
||||
{
|
||||
hResource = HttpOpenRequest (hConnect,
|
||||
TEXT ("GET"),
|
||||
TEXT ("/hexchat/hexchat/master/win32/version.txt"),
|
||||
TEXT ("HTTP/1.0"),
|
||||
NULL,
|
||||
NULL,
|
||||
INTERNET_FLAG_SECURE | INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_AUTH,
|
||||
0);
|
||||
}
|
||||
|
||||
|
||||
hResource = HttpOpenRequest (hConnect,
|
||||
TEXT ("GET"),
|
||||
TEXT ("/hexchat/hexchat/master/win32/version.txt"),
|
||||
TEXT ("HTTP/1.0"),
|
||||
NULL,
|
||||
NULL,
|
||||
INTERNET_FLAG_SECURE | INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_AUTH,
|
||||
0);
|
||||
if (!hResource)
|
||||
{
|
||||
InternetCloseHandle (hConnect);
|
||||
@ -154,7 +83,11 @@ check_version ()
|
||||
else
|
||||
{
|
||||
static char buffer[1024];
|
||||
char infobuffer[32];
|
||||
int statuscode;
|
||||
|
||||
DWORD dwRead;
|
||||
DWORD infolen = sizeof(infobuffer);
|
||||
|
||||
HttpAddRequestHeaders (hResource, TEXT ("Connection: close\r\n"), -1L, HTTP_ADDREQ_FLAG_ADD); /* workaround for GC bug */
|
||||
HttpSendRequest (hResource, NULL, 0, NULL, 0);
|
||||
@ -168,10 +101,18 @@ check_version ()
|
||||
buffer[dwRead] = 0;
|
||||
}
|
||||
|
||||
HttpQueryInfo(hResource,
|
||||
HTTP_QUERY_STATUS_CODE,
|
||||
&infobuffer,
|
||||
&infolen,
|
||||
NULL);
|
||||
|
||||
InternetCloseHandle (hResource);
|
||||
InternetCloseHandle (hConnect);
|
||||
InternetCloseHandle (hOpen);
|
||||
if (strlen (buffer) == 5)
|
||||
|
||||
statuscode = atoi(infobuffer);
|
||||
if (statuscode == 200)
|
||||
return buffer;
|
||||
else
|
||||
return "Unknown";
|
||||
@ -250,9 +191,9 @@ print_version (char *word[], char *word_eol[], void *userdata)
|
||||
else
|
||||
{
|
||||
#ifdef _WIN64 /* use this approach, the wProcessorArchitecture method always returns 0 (=x86) for some reason */
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\nhttp://dl.hexchat.org/hexchat/HexChat%%20%s%%20x64.exe\n", name, version);
|
||||
hexchat_printf (ph, "%s:\tA HexChat update is available! You can download it from here:\n%s/HexChat%%20%s%%20x64.exe\n", name, DOWNLOAD_URL, version);
|
||||
#else
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\nhttp://dl.hexchat.org/hexchat/HexChat%%20%s%%20x86.exe\n", name, version);
|
||||
hexchat_printf (ph, "%s:\tA HexChat update is available! You can download it from here:\n%s/HexChat%%20%s%%20x86.exe\n", name, DOWNLOAD_URL, version);
|
||||
#endif
|
||||
}
|
||||
return HEXCHAT_EAT_HEXCHAT;
|
||||
@ -273,9 +214,9 @@ print_version_quiet (void *userdata)
|
||||
if (!(strcmp (version, hexchat_get_info (ph, "version")) == 0) && !(strcmp (version, "Unknown") == 0))
|
||||
{
|
||||
#ifdef _WIN64 /* use this approach, the wProcessorArchitecture method always returns 0 (=x86) for plugins for some reason */
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\nhttps://github.com/downloads/hexchat/hexchat/HexChat%%20%s%%20x64.exe\n", name, version);
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\n%s/HexChat%%20%s%%20x64.exe\n", name, DOWNLOAD_URL, version);
|
||||
#else
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\nhttps://github.com/downloads/hexchat/hexchat/HexChat%%20%s%%20x86.exe\n", name, version);
|
||||
hexchat_printf (ph, "%s\tA HexChat update is available! You can download it from here:\n%s/HexChat%%20%s%%20x86.exe\n", name, DOWNLOAD_URL, version);
|
||||
#endif
|
||||
/* print update url once, then stop the timer */
|
||||
return 0;
|
||||
@ -303,21 +244,12 @@ int
|
||||
hexchat_plugin_init (hexchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
|
||||
{
|
||||
int delay;
|
||||
OSVERSIONINFOEX osvi;
|
||||
ph = plugin_handle;
|
||||
|
||||
*plugin_name = name;
|
||||
*plugin_desc = desc;
|
||||
*plugin_version = version;
|
||||
|
||||
osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
|
||||
GetVersionEx ((OSVERSIONINFO*) &osvi);
|
||||
|
||||
if (osvi.dwMajorVersion == 5)
|
||||
{
|
||||
legacy_os = 1;
|
||||
}
|
||||
|
||||
/* these are required for the very first run */
|
||||
delay = hexchat_pluginpref_get_int (ph, "delay");
|
||||
if (delay == -1)
|
||||
@ -333,7 +265,7 @@ hexchat_plugin_init (hexchat_plugin *plugin_handle, char **plugin_name, char **p
|
||||
|
||||
hexchat_hook_command (ph, "UPDCHK", HEXCHAT_PRI_NORM, print_version, upd_help, NULL);
|
||||
hexchat_hook_timer (ph, delay * 1000, delayed_check, NULL);
|
||||
hexchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
|
||||
hexchat_command (ph, "MENU -ishare\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
|
||||
hexchat_printf (ph, "%s plugin loaded\n", name);
|
||||
|
||||
return 1; /* return 1 for success */
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;UPD_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -77,7 +79,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;UPD_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -173,7 +173,7 @@ hexchat_plugin_init(hexchat_plugin *plugin_handle,
|
||||
*plugin_version = "0.5";
|
||||
|
||||
hexchat_hook_command (ph, "WINAMP", HEXCHAT_PRI_NORM, winamp, "Usage: /WINAMP [PAUSE|PLAY|STOP|NEXT|PREV|START] - control Winamp or show what's currently playing", 0);
|
||||
hexchat_command (ph, "MENU -ietc\\music.png ADD \"Window/Display Current Song (Winamp)\" \"WINAMP\"");
|
||||
hexchat_command (ph, "MENU -ishare\\music.png ADD \"Window/Display Current Song (Winamp)\" \"WINAMP\"");
|
||||
|
||||
hexchat_print (ph, "Winamp plugin loaded\n");
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Configuration">
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
@ -56,7 +59,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;WINAMP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
@ -75,7 +77,6 @@
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;WINAMP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -1,70 +0,0 @@
|
||||
========================================================================
|
||||
MICROSOFT FOUNDATION CLASS LIBRARY : wmpa
|
||||
========================================================================
|
||||
|
||||
|
||||
AppWizard has created this wmpa DLL for you. This DLL not only
|
||||
demonstrates the basics of using the Microsoft Foundation classes but
|
||||
is also a starting point for writing your DLL.
|
||||
|
||||
This file contains a summary of what you will find in each of the files that
|
||||
make up your wmpa DLL.
|
||||
|
||||
wmpa.dsp
|
||||
This file (the project file) contains information at the project level and
|
||||
is used to build a single project or subproject. Other users can share the
|
||||
project (.dsp) file, but they should export the makefiles locally.
|
||||
|
||||
wmpa.h
|
||||
This is the main header file for the DLL. It declares the
|
||||
CWmpaApp class.
|
||||
|
||||
wmpa.cpp
|
||||
This is the main DLL source file. It contains the class CWmpaApp.
|
||||
It also contains the OLE entry points required of inproc servers.
|
||||
|
||||
wmpa.odl
|
||||
This file contains the Object Description Language source code for the
|
||||
type library of your DLL.
|
||||
|
||||
wmpa.rc
|
||||
This is a listing of all of the Microsoft Windows resources that the
|
||||
program uses. It includes the icons, bitmaps, and cursors that are stored
|
||||
in the RES subdirectory. This file can be directly edited in Microsoft
|
||||
Visual C++.
|
||||
|
||||
wmpa.clw
|
||||
This file contains information used by ClassWizard to edit existing
|
||||
classes or add new classes. ClassWizard also uses this file to store
|
||||
information needed to create and edit message maps and dialog data
|
||||
maps and to create prototype member functions.
|
||||
|
||||
res\wmpa.rc2
|
||||
This file contains resources that are not edited by Microsoft
|
||||
Visual C++. You should place all resources not editable by
|
||||
the resource editor in this file.
|
||||
|
||||
wmpa.def
|
||||
This file contains information about the DLL that must be
|
||||
provided to run with Microsoft Windows. It defines parameters
|
||||
such as the name and description of the DLL. It also exports
|
||||
functions from the DLL.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
Other standard files:
|
||||
|
||||
StdAfx.h, StdAfx.cpp
|
||||
These files are used to build a precompiled header (PCH) file
|
||||
named wmpa.pch and a precompiled types file named StdAfx.obj.
|
||||
|
||||
Resource.h
|
||||
This is the standard header file, which defines new resource IDs.
|
||||
Microsoft Visual C++ reads and updates this file.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
Other notes:
|
||||
|
||||
AppWizard uses "TODO:" to indicate parts of the source code you
|
||||
should add to or customize.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
@ -1,8 +0,0 @@
|
||||
// stdafx.cpp : source file that includes just the standard includes
|
||||
// wmpa.pch will be the pre-compiled header
|
||||
// stdafx.obj will contain the pre-compiled type information
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
|
@ -1,62 +0,0 @@
|
||||
// stdafx.h : include file for standard system include files,
|
||||
// or project specific include files that are used frequently, but
|
||||
// are changed infrequently
|
||||
//
|
||||
|
||||
#if !defined(AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_)
|
||||
#define AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
|
||||
|
||||
#include <afxwin.h> // MFC core and standard components
|
||||
#include <afxext.h> // MFC extensions
|
||||
|
||||
#ifndef _AFX_NO_OLE_SUPPORT
|
||||
#include <afxole.h> // MFC OLE classes
|
||||
#include <afxodlgs.h> // MFC OLE dialog classes
|
||||
#include <afxdisp.h> // MFC Automation classes
|
||||
#endif // _AFX_NO_OLE_SUPPORT
|
||||
|
||||
|
||||
#ifndef _AFX_NO_DB_SUPPORT
|
||||
#include <afxdb.h> // MFC ODBC database classes
|
||||
#endif // _AFX_NO_DB_SUPPORT
|
||||
|
||||
#ifndef _AFX_NO_DAO_SUPPORT
|
||||
#include <afxdao.h> // MFC DAO database classes
|
||||
#endif // _AFX_NO_DAO_SUPPORT
|
||||
|
||||
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
|
||||
#ifndef _AFX_NO_AFXCMN_SUPPORT
|
||||
#include <afxcmn.h> // MFC support for Windows Common Controls
|
||||
#endif // _AFX_NO_AFXCMN_SUPPORT
|
||||
|
||||
/******************************************************************
|
||||
* Includes
|
||||
******************************************************************/
|
||||
#include "wmpcdrom.h"
|
||||
#include "wmpcdromcollection.h"
|
||||
#include "wmpclosedcaption.h"
|
||||
#include "wmpcontrols.h"
|
||||
#include "wmpdvd.h"
|
||||
#include "wmperror.h"
|
||||
#include "wmperroritem.h"
|
||||
#include "wmpmedia.h"
|
||||
#include "wmpmediacollection.h"
|
||||
#include "wmpnetwork.h"
|
||||
#include "wmpplayer4.h"
|
||||
#include "wmpplayerapplication.h"
|
||||
#include "wmpplaylist.h"
|
||||
#include "wmpplaylistarray.h"
|
||||
#include "wmpplaylistcollection.h"
|
||||
#include "wmpsettings.h"
|
||||
#include "wmpstringcollection.h"
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_)
|
@ -1,590 +0,0 @@
|
||||
/******************************************************************
|
||||
* $Id$
|
||||
*
|
||||
* $Log$
|
||||
*
|
||||
* Copyright <20> 2005 David Cullen, All rights reserved
|
||||
*
|
||||
******************************************************************/
|
||||
#include "stdafx.h"
|
||||
#include "hexchat-plugin.h"
|
||||
#include <windows.h>
|
||||
#include <tchar.h>
|
||||
#include "wmpa.h"
|
||||
#include "WMPADialog.h"
|
||||
|
||||
#define XMMS_SESSION 0
|
||||
|
||||
/******************************************************************
|
||||
* Globalss
|
||||
******************************************************************/
|
||||
hexchat_plugin *ph = NULL;
|
||||
CWMPPlayer4 *wmp;
|
||||
static const char subKey[] = "Software\\FlowerSoft\\WMPA";
|
||||
|
||||
/******************************************************************
|
||||
* hexchat_plugin_init
|
||||
******************************************************************/
|
||||
int hexchat_plugin_init(hexchat_plugin *plugin_handle,
|
||||
char **plugin_name,
|
||||
char **plugin_desc,
|
||||
char **plugin_version,
|
||||
char *arg)
|
||||
{
|
||||
BOOL success;
|
||||
|
||||
ph = plugin_handle;
|
||||
|
||||
*plugin_name = "WMPA";
|
||||
*plugin_desc = "Announce the current song from Windows Media Player.";
|
||||
*plugin_version = VER_STRING;
|
||||
|
||||
// Show the song browser
|
||||
success = StartWindowsMediaPlayer();
|
||||
if (!success) {
|
||||
hexchat_printf(ph, "WMPA: Failed to show the song browser.");
|
||||
hexchat_printf(ph, "WMPA: Could not load plug-in version %s.", VER_STRING);
|
||||
return(E_FAIL);
|
||||
}
|
||||
|
||||
// Get a pointer to the Windows Media Player control
|
||||
wmp = GetWindowsMediaPlayer();
|
||||
if (wmp == NULL) {
|
||||
hexchat_printf(ph, "WMPA: Failed to get a pointer to the Windows Media Player interface.");
|
||||
hexchat_printf(ph, "WMPA: Could not load plug-in version %s.", VER_STRING);
|
||||
return(E_POINTER);
|
||||
}
|
||||
|
||||
// Restore the settings (need wmp first)
|
||||
success = wmpaRestoreSettings();
|
||||
if (!success) {
|
||||
hexchat_printf(ph, "WMPA: Failed to restore the settings.");
|
||||
}
|
||||
|
||||
hexchat_hook_command(ph, "auto", HEXCHAT_PRI_NORM, wmpaAuto, 0, 0);
|
||||
hexchat_hook_command(ph, "curr", HEXCHAT_PRI_NORM, wmpaCurr, 0, 0);
|
||||
hexchat_hook_command(ph, "find", HEXCHAT_PRI_NORM, wmpaFind, 0, 0);
|
||||
hexchat_hook_command(ph, "slist", HEXCHAT_PRI_NORM, wmpaList, 0, 0);
|
||||
hexchat_hook_command(ph, "next", HEXCHAT_PRI_NORM, wmpaNext, 0, 0);
|
||||
hexchat_hook_command(ph, "play", HEXCHAT_PRI_NORM, wmpaPlay, 0, 0);
|
||||
hexchat_hook_command(ph, "pause", HEXCHAT_PRI_NORM, wmpaPause, 0, 0);
|
||||
hexchat_hook_command(ph, "prev", HEXCHAT_PRI_NORM, wmpaPrev, 0, 0);
|
||||
hexchat_hook_command(ph, "song", HEXCHAT_PRI_NORM, wmpaSong, 0, 0);
|
||||
hexchat_hook_command(ph, "stop", HEXCHAT_PRI_NORM, wmpaStop, 0, 0);
|
||||
hexchat_hook_command(ph, "volume", HEXCHAT_PRI_NORM, wmpaVolume, 0, 0);
|
||||
hexchat_hook_command(ph, "wmpahelp", HEXCHAT_PRI_NORM, wmpaHelp, 0, 0);
|
||||
|
||||
hexchat_printf(ph, "WMPA %s successfully loaded.", VER_STRING);
|
||||
wmpaCommands();
|
||||
hexchat_printf(ph, "WMPA: e-mail me if you find any bugs: dcullen@intergate.com");
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* hexchat_plugin_deinit
|
||||
******************************************************************/
|
||||
int hexchat_plugin_deinit(void)
|
||||
{
|
||||
BOOL success;
|
||||
|
||||
hexchat_printf(ph, "WMPA %s is unloading.", VER_STRING);
|
||||
|
||||
// Save the settings
|
||||
success = wmpaSaveSettings();
|
||||
if (!success) {
|
||||
hexchat_printf(ph, "WMPA: Failed to save the settings.");
|
||||
}
|
||||
|
||||
wmp = NULL;
|
||||
|
||||
BOOL result = StopWindowsMediaPlayer();
|
||||
if (!result) {
|
||||
hexchat_printf(ph, "WMPA could not shut down Windows Media Player.");
|
||||
}
|
||||
|
||||
hexchat_printf(ph, "WMPA %s has unloaded.", VER_STRING);
|
||||
return 1;
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* hexchat_plugin_get_info
|
||||
******************************************************************/
|
||||
void hexchat_plugin_get_info(char **name, char **desc, char **version, void **reserved)
|
||||
{
|
||||
*name = "WMPA";
|
||||
*desc = "Announce the current song from Windows Media Player.";
|
||||
*version = VER_STRING;
|
||||
if (reserved) *reserved = NULL;
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaCommands
|
||||
******************************************************************/
|
||||
void wmpaCommands(void)
|
||||
{
|
||||
hexchat_printf(ph, "WMPA: /auto [on/off] : Turn on/off auto announce of the current song or display the current setting");
|
||||
hexchat_printf(ph, "WMPA: /curr : Tell what song is currently playing");
|
||||
hexchat_printf(ph, "WMPA: /find [word] : Find songs with \"word\" in their title, create a new playlist, and play it");
|
||||
hexchat_printf(ph, "WMPA: /slist [word] : List songs with \"word\" in their title");
|
||||
hexchat_printf(ph, "WMPA: /next : Play the next song");
|
||||
hexchat_printf(ph, "WMPA: /play : Play the current song");
|
||||
hexchat_printf(ph, "WMPA: /pause : Pause the current song");
|
||||
hexchat_printf(ph, "WMPA: /prev : Play the previous song");
|
||||
hexchat_printf(ph, "WMPA: /song : Announce the current song from Windows Media Player in HexChat");
|
||||
hexchat_printf(ph, "WMPA: /stop : Stop the current song");
|
||||
hexchat_printf(ph, "WMPA: /volume [volume] : Set the volume (0 to 100) or display the current volume");
|
||||
hexchat_printf(ph, "WMPA: /wmpahelp : Display this help.");
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaAuto
|
||||
******************************************************************/
|
||||
int wmpaAuto(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
CWMPADialog *pDialog;
|
||||
char *state;
|
||||
|
||||
pDialog = GetWMPADialog();
|
||||
if (pDialog == NULL) return(HEXCHAT_EAT_ALL);
|
||||
|
||||
if (CString(word[2]).IsEmpty()) {
|
||||
if (pDialog->autoAnnounce) {
|
||||
state = "on";
|
||||
}
|
||||
else {
|
||||
state = "off";
|
||||
}
|
||||
}
|
||||
else {
|
||||
state = word[2];
|
||||
if (CString(state) == "on") {
|
||||
pDialog->autoAnnounce = TRUE;
|
||||
}
|
||||
if (CString(state) == "off") {
|
||||
pDialog->autoAnnounce = FALSE;
|
||||
}
|
||||
wmpaSaveSettings();
|
||||
}
|
||||
|
||||
hexchat_printf(ph, "WMPA: auto is %s", state);
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaCurr
|
||||
******************************************************************/
|
||||
int wmpaCurr(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaFind
|
||||
******************************************************************/
|
||||
int wmpaFind(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
long index;
|
||||
long count;
|
||||
long found;
|
||||
|
||||
if (wmp != NULL) {
|
||||
CWMPMediaCollection mc = wmp->GetMediaCollection();
|
||||
CWMPPlaylist all = mc.getAll();
|
||||
CWMPPlaylistCollection pc = wmp->GetPlaylistCollection();
|
||||
CWMPPlaylistArray pa = pc.getAll();
|
||||
CWMPPlaylist playlist;
|
||||
CWMPMedia media;
|
||||
|
||||
for (index = 0; index < pc.getAll().GetCount(); index++) {
|
||||
if (pc.getAll().Item(index).GetName() == CString(word_eol[2])) {
|
||||
playlist = pc.getAll().Item(index);
|
||||
pc.remove(playlist);
|
||||
}
|
||||
}
|
||||
|
||||
playlist = pc.newPlaylist(word_eol[2]);
|
||||
|
||||
count = all.GetCount();
|
||||
found = 0;
|
||||
for (index = 0; index < count; index++) {
|
||||
media = all.GetItem(index);
|
||||
CString artist = media.getItemInfo("Artist");
|
||||
CString title = media.getItemInfo("Title");
|
||||
CString album = media.getItemInfo("Album");
|
||||
if ( (artist.Find(word_eol[2]) != -1) ||
|
||||
(title.Find(word_eol[2]) != -1) ||
|
||||
(album.Find(word_eol[2]) != -1) ) {
|
||||
playlist.appendItem(media);
|
||||
found++;
|
||||
}
|
||||
}
|
||||
|
||||
if (found > 0) {
|
||||
hexchat_printf(ph, "WMPA: Found %d songs with \"%s\" in them", found, word_eol[2]);
|
||||
wmp->SetCurrentPlaylist(playlist);
|
||||
wmp->GetControls().play();
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
|
||||
CWMPADialog *dialog = GetWMPADialog();
|
||||
if (dialog != NULL) {
|
||||
dialog->UpdateSongList();
|
||||
dialog->SelectCurrentSong();
|
||||
dialog->UpdatePlayLists();
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
hexchat_printf(ph, "WMPA: Could not find %s", word_eol[2]);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaList
|
||||
******************************************************************/
|
||||
int wmpaList(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
long index;
|
||||
long count;
|
||||
long found;
|
||||
|
||||
if (wmp != NULL) {
|
||||
hexchat_printf(ph, "WMPA: Listing songs with \"%s\" in them", word_eol[2]);
|
||||
|
||||
CWMPMediaCollection mc = wmp->GetMediaCollection();
|
||||
CWMPPlaylist all = mc.getAll();
|
||||
CWMPMedia media;
|
||||
|
||||
count = all.GetCount();
|
||||
found = 0;
|
||||
for (index = 0; index < count; index++) {
|
||||
media = all.GetItem(index);
|
||||
CString artist = media.getItemInfo("Artist");
|
||||
CString title = media.getItemInfo("Title");
|
||||
CString album = media.getItemInfo("Album");
|
||||
if ( (artist.Find(word_eol[2]) != -1) ||
|
||||
(title.Find(word_eol[2]) != -1) ||
|
||||
(album.Find(word_eol[2]) != -1) ) {
|
||||
hexchat_printf(ph, "WMPA: Found \"%s - %s (%s)\"", artist, title, album);
|
||||
found++;
|
||||
}
|
||||
}
|
||||
|
||||
if (found > 0) {
|
||||
if (found == 1)
|
||||
hexchat_printf(ph, "WMPA: Found %d song with \"%s\" in it", found, word_eol[2]);
|
||||
else
|
||||
hexchat_printf(ph, "WMPA: Found %d songs with \"%s\" in them", found, word_eol[2]);
|
||||
}
|
||||
else {
|
||||
hexchat_printf(ph, "WMPA: Could not find any songs with \"%s\" in them", word_eol[2]);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaNext
|
||||
******************************************************************/
|
||||
int wmpaNext(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
if (wmp != NULL) {
|
||||
wmp->GetControls().next();
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaPlay
|
||||
******************************************************************/
|
||||
int wmpaPlay(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
if (wmp != NULL) {
|
||||
wmp->GetControls().play();
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaPause
|
||||
******************************************************************/
|
||||
int wmpaPause(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
if (wmp != NULL) {
|
||||
wmp->GetControls().pause();
|
||||
hexchat_printf(ph, "WMPA: Pausing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaPrev
|
||||
******************************************************************/
|
||||
int wmpaPrev(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
if (wmp != NULL) {
|
||||
wmp->GetControls().previous();
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaSong
|
||||
******************************************************************/
|
||||
int wmpaSong(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
CString songTitle = wmpaGetSongTitle();
|
||||
|
||||
hexchat_commandf(ph, "me is playing %s", (LPCTSTR) songTitle);
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaStop
|
||||
******************************************************************/
|
||||
int wmpaStop(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
if (wmp != NULL) {
|
||||
wmp->GetControls().stop();
|
||||
hexchat_printf(ph, "WMPA: Stopping %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaHelp
|
||||
******************************************************************/
|
||||
int wmpaHelp(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
hexchat_printf(ph, "\n");
|
||||
hexchat_printf(ph, "WMPA %s Help", VER_STRING);
|
||||
wmpaCommands();
|
||||
hexchat_printf(ph, "\n");
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaVolume
|
||||
******************************************************************/
|
||||
int wmpaVolume(char *word[], char *word_eol[], void *user_data)
|
||||
{
|
||||
char *endPtr;
|
||||
long volume;
|
||||
|
||||
if (CString(word[2]).IsEmpty()) {
|
||||
volume = wmp->GetSettings().GetVolume();
|
||||
}
|
||||
else {
|
||||
volume = strtol(word[2], &endPtr, 10);
|
||||
|
||||
if ((wmp != NULL) && (volume >= 0) && (volume <= 100)) {
|
||||
wmp->GetSettings().SetVolume(volume);
|
||||
wmpaSaveSettings();
|
||||
}
|
||||
}
|
||||
|
||||
hexchat_printf(ph, "WMPA: volume is %d", volume);
|
||||
|
||||
return(HEXCHAT_EAT_ALL);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaRestoreSettings
|
||||
******************************************************************/
|
||||
BOOL wmpaRestoreSettings(void)
|
||||
{
|
||||
CWMPADialog *pDialog;
|
||||
DWORD type;
|
||||
int volume;
|
||||
BOOL autoAnnounce;
|
||||
DWORD size;
|
||||
BOOL result;
|
||||
|
||||
if (wmp == NULL) return(FALSE);
|
||||
|
||||
volume = 50;
|
||||
result = GetSetting("Volume", &type, (LPBYTE) &volume, &size);
|
||||
wmp->GetSettings().SetVolume(volume);
|
||||
|
||||
autoAnnounce = FALSE;
|
||||
pDialog = GetWMPADialog();
|
||||
if (pDialog != NULL) {
|
||||
result = result && GetSetting("Auto", &type, (LPBYTE) &autoAnnounce, &size);
|
||||
pDialog->autoAnnounce = autoAnnounce;
|
||||
}
|
||||
else {
|
||||
result = FALSE;
|
||||
}
|
||||
|
||||
return(result);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaSaveSettings
|
||||
******************************************************************/
|
||||
BOOL wmpaSaveSettings(void)
|
||||
{
|
||||
CWMPADialog *pDialog;
|
||||
int volume;
|
||||
BOOL autoAnnounce;
|
||||
BOOL result;
|
||||
|
||||
if (wmp == NULL) return(FALSE);
|
||||
|
||||
volume = wmp->GetSettings().GetVolume();
|
||||
result = SaveSetting("Volume", REG_DWORD, (CONST BYTE *) &volume, sizeof(volume));
|
||||
|
||||
pDialog = GetWMPADialog();
|
||||
if (pDialog != NULL) {
|
||||
autoAnnounce = pDialog->autoAnnounce;
|
||||
result = result && SaveSetting("Auto", REG_DWORD, (CONST BYTE *) &autoAnnounce, sizeof(autoAnnounce));
|
||||
}
|
||||
else {
|
||||
result = FALSE;
|
||||
}
|
||||
|
||||
return(result);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* wmpaGetSongTitle
|
||||
******************************************************************/
|
||||
CString wmpaGetSongTitle(void)
|
||||
{
|
||||
char buffer[32];
|
||||
|
||||
if (wmp == NULL) return(CString());
|
||||
|
||||
CWMPMedia media = wmp->GetCurrentMedia();
|
||||
if (media == NULL) {
|
||||
hexchat_printf(ph, "WMPA: Could not get current media");
|
||||
return(CString ("%d", HEXCHAT_EAT_ALL));
|
||||
}
|
||||
|
||||
CString artist = media.getItemInfo("Artist");
|
||||
CString title = media.getItemInfo("Title");
|
||||
CString album = media.getItemInfo("Album");
|
||||
CString bitrate = media.getItemInfo("Bitrate");
|
||||
CString duration = media.GetDurationString();
|
||||
|
||||
long krate = strtoul((LPCTSTR) bitrate, NULL, 10) / 1000;
|
||||
_ultoa(krate, buffer, 10);
|
||||
bitrate = CString(buffer);
|
||||
|
||||
// Creatte the song title
|
||||
CString songTitle("");
|
||||
songTitle += artist;
|
||||
if (songTitle.IsEmpty()) songTitle += "Various";
|
||||
songTitle += " - ";
|
||||
songTitle += title;
|
||||
songTitle += " (";
|
||||
songTitle += album;
|
||||
songTitle += ") [";
|
||||
songTitle += duration;
|
||||
songTitle += "/";
|
||||
songTitle += bitrate;
|
||||
songTitle += "Kbps]";
|
||||
|
||||
return(songTitle);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* SaveSetting
|
||||
******************************************************************/
|
||||
BOOL SaveSetting(LPCTSTR name, DWORD type, CONST BYTE *value, DWORD size)
|
||||
{
|
||||
HKEY hKey;
|
||||
DWORD disposition;
|
||||
LONG result;
|
||||
|
||||
if (wmp == NULL) return(FALSE);
|
||||
if (name == NULL) return(FALSE);
|
||||
|
||||
result = RegOpenKeyEx(HKEY_CURRENT_USER,
|
||||
subKey,
|
||||
0,
|
||||
KEY_WRITE,
|
||||
&hKey);
|
||||
|
||||
if (result != ERROR_SUCCESS) {
|
||||
result = RegCreateKeyEx(HKEY_CURRENT_USER,
|
||||
subKey,
|
||||
0,
|
||||
NULL,
|
||||
REG_OPTION_NON_VOLATILE,
|
||||
KEY_WRITE,
|
||||
NULL,
|
||||
&hKey,
|
||||
&disposition);
|
||||
|
||||
if (result != ERROR_SUCCESS) return(FALSE);
|
||||
}
|
||||
|
||||
result = RegSetValueEx(hKey,
|
||||
name,
|
||||
0,
|
||||
type,
|
||||
value,
|
||||
size);
|
||||
|
||||
if (result == ERROR_SUCCESS) {
|
||||
RegCloseKey(hKey);
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
RegCloseKey(hKey);
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* GetSetting
|
||||
******************************************************************/
|
||||
BOOL GetSetting(LPCTSTR name, DWORD *type, LPBYTE value, DWORD *size)
|
||||
{
|
||||
HKEY hKey;
|
||||
LONG result;
|
||||
|
||||
if (wmp == NULL) return(FALSE);
|
||||
if (type == NULL) return(FALSE);
|
||||
if (value == NULL) return(FALSE);
|
||||
if (size == NULL) return(FALSE);
|
||||
|
||||
result = RegOpenKeyEx(HKEY_CURRENT_USER,
|
||||
subKey,
|
||||
0,
|
||||
KEY_READ,
|
||||
&hKey);
|
||||
|
||||
if (result != ERROR_SUCCESS) return(FALSE);
|
||||
|
||||
result = RegQueryValueEx(hKey,
|
||||
name,
|
||||
0,
|
||||
type,
|
||||
value,
|
||||
size);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
|
||||
if (result == ERROR_SUCCESS) {
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
RegCloseKey(hKey);
|
||||
return(FALSE);
|
||||
}
|
||||
|
@ -1,361 +0,0 @@
|
||||
/* You can distribute this header with your plugins for easy compilation */
|
||||
#ifndef HEXCHAT_PLUGIN_H
|
||||
#define HEXCHAT_PLUGIN_H
|
||||
|
||||
#define VER_STRING _T("1.0.2 (BETA)")
|
||||
|
||||
#include "stdafx.h"
|
||||
#include <windows.h>
|
||||
#include <time.h>
|
||||
#include <tchar.h>
|
||||
|
||||
#define HEXCHAT_PRI_HIGHEST 127
|
||||
#define HEXCHAT_PRI_HIGH 64
|
||||
#define HEXCHAT_PRI_NORM 0
|
||||
#define HEXCHAT_PRI_LOW (-64)
|
||||
#define HEXCHAT_PRI_LOWEST (-128)
|
||||
|
||||
#define HEXCHAT_FD_READ 1
|
||||
#define HEXCHAT_FD_WRITE 2
|
||||
#define HEXCHAT_FD_EXCEPTION 4
|
||||
#define HEXCHAT_FD_NOTSOCKET 8
|
||||
|
||||
#define HEXCHAT_EAT_NONE 0 /* pass it on through! */
|
||||
#define HEXCHAT_EAT_HEXCHAT 1 /* don't let HexChat see this event */
|
||||
#define HEXCHAT_EAT_PLUGIN 2 /* don't let other plugins see this event */
|
||||
#define HEXCHAT_EAT_ALL (HEXCHAT_EAT_HEXCHAT|HEXCHAT_EAT_PLUGIN) /* don't let anything see this event */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
typedef struct _hexchat_plugin hexchat_plugin;
|
||||
typedef struct _hexchat_list hexchat_list;
|
||||
typedef struct _hexchat_hook hexchat_hook;
|
||||
#ifndef PLUGIN_C
|
||||
typedef struct _hexchat_context hexchat_context;
|
||||
#endif
|
||||
|
||||
#ifndef PLUGIN_C
|
||||
struct _hexchat_plugin {
|
||||
/* these are only used on win32 */
|
||||
hexchat_hook *(*hexchat_hook_command) (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], char *word_eol[], void *user_data),
|
||||
const char *help_text,
|
||||
void *userdata);
|
||||
hexchat_hook *(*hexchat_hook_server) (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], char *word_eol[], void *user_data),
|
||||
void *userdata);
|
||||
hexchat_hook *(*hexchat_hook_print) (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], void *user_data),
|
||||
void *userdata);
|
||||
hexchat_hook *(*hexchat_hook_timer) (hexchat_plugin *ph,
|
||||
int timeout,
|
||||
int (*callback) (void *user_data),
|
||||
void *userdata);
|
||||
hexchat_hook *(*hexchat_hook_fd) (hexchat_plugin *ph,
|
||||
int fd,
|
||||
int flags,
|
||||
int (*callback) (int fd, int flags, void *user_data),
|
||||
void *userdata);
|
||||
void *(*hexchat_unhook) (hexchat_plugin *ph,
|
||||
hexchat_hook *hook);
|
||||
void (*hexchat_print) (hexchat_plugin *ph,
|
||||
const char *text);
|
||||
void (*hexchat_printf) (hexchat_plugin *ph,
|
||||
const char *format, ...);
|
||||
void (*hexchat_command) (hexchat_plugin *ph,
|
||||
const char *command);
|
||||
void (*hexchat_commandf) (hexchat_plugin *ph,
|
||||
const char *format, ...);
|
||||
int (*hexchat_nickcmp) (hexchat_plugin *ph,
|
||||
const char *s1,
|
||||
const char *s2);
|
||||
int (*hexchat_set_context) (hexchat_plugin *ph,
|
||||
hexchat_context *ctx);
|
||||
hexchat_context *(*hexchat_find_context) (hexchat_plugin *ph,
|
||||
const char *servname,
|
||||
const char *channel);
|
||||
hexchat_context *(*hexchat_get_context) (hexchat_plugin *ph);
|
||||
const char *(*hexchat_get_info) (hexchat_plugin *ph,
|
||||
const char *id);
|
||||
int (*hexchat_get_prefs) (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
const char **string,
|
||||
int *integer);
|
||||
hexchat_list * (*hexchat_list_get) (hexchat_plugin *ph,
|
||||
const char *name);
|
||||
void (*hexchat_list_free) (hexchat_plugin *ph,
|
||||
hexchat_list *xlist);
|
||||
const char * const * (*hexchat_list_fields) (hexchat_plugin *ph,
|
||||
const char *name);
|
||||
int (*hexchat_list_next) (hexchat_plugin *ph,
|
||||
hexchat_list *xlist);
|
||||
const char * (*hexchat_list_str) (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
int (*hexchat_list_int) (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
void * (*hexchat_plugingui_add) (hexchat_plugin *ph,
|
||||
const char *filename,
|
||||
const char *name,
|
||||
const char *desc,
|
||||
const char *version,
|
||||
char *reserved);
|
||||
void (*hexchat_plugingui_remove) (hexchat_plugin *ph,
|
||||
void *handle);
|
||||
int (*hexchat_emit_print) (hexchat_plugin *ph,
|
||||
const char *event_name, ...);
|
||||
int (*hexchat_read_fd) (hexchat_plugin *ph,
|
||||
void *src,
|
||||
char *buf,
|
||||
int *len);
|
||||
time_t (*hexchat_list_time) (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
char *(*hexchat_gettext) (hexchat_plugin *ph,
|
||||
const char *msgid);
|
||||
void (*hexchat_send_modes) (hexchat_plugin *ph,
|
||||
const char **targets,
|
||||
int ntargets,
|
||||
int modes_per_line,
|
||||
char sign,
|
||||
char mode);
|
||||
char *(*hexchat_strip) (hexchat_plugin *ph,
|
||||
const char *str,
|
||||
int len,
|
||||
int flags);
|
||||
void (*hexchat_free) (hexchat_plugin *ph,
|
||||
void *ptr);
|
||||
};
|
||||
#endif
|
||||
|
||||
|
||||
hexchat_hook *
|
||||
hexchat_hook_command (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], char *word_eol[], void *user_data),
|
||||
const char *help_text,
|
||||
void *userdata);
|
||||
|
||||
hexchat_hook *
|
||||
hexchat_hook_server (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], char *word_eol[], void *user_data),
|
||||
void *userdata);
|
||||
|
||||
hexchat_hook *
|
||||
hexchat_hook_print (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
int pri,
|
||||
int (*callback) (char *word[], void *user_data),
|
||||
void *userdata);
|
||||
|
||||
hexchat_hook *
|
||||
hexchat_hook_timer (hexchat_plugin *ph,
|
||||
int timeout,
|
||||
int (*callback) (void *user_data),
|
||||
void *userdata);
|
||||
|
||||
hexchat_hook *
|
||||
hexchat_hook_fd (hexchat_plugin *ph,
|
||||
int fd,
|
||||
int flags,
|
||||
int (*callback) (int fd, int flags, void *user_data),
|
||||
void *userdata);
|
||||
|
||||
void *
|
||||
hexchat_unhook (hexchat_plugin *ph,
|
||||
hexchat_hook *hook);
|
||||
|
||||
void
|
||||
hexchat_print (hexchat_plugin *ph,
|
||||
const char *text);
|
||||
|
||||
void
|
||||
hexchat_printf (hexchat_plugin *ph,
|
||||
const char *format, ...);
|
||||
|
||||
void
|
||||
hexchat_command (hexchat_plugin *ph,
|
||||
const char *command);
|
||||
|
||||
void
|
||||
hexchat_commandf (hexchat_plugin *ph,
|
||||
const char *format, ...);
|
||||
|
||||
int
|
||||
hexchat_nickcmp (hexchat_plugin *ph,
|
||||
const char *s1,
|
||||
const char *s2);
|
||||
|
||||
int
|
||||
hexchat_set_context (hexchat_plugin *ph,
|
||||
hexchat_context *ctx);
|
||||
|
||||
hexchat_context *
|
||||
hexchat_find_context (hexchat_plugin *ph,
|
||||
const char *servname,
|
||||
const char *channel);
|
||||
|
||||
hexchat_context *
|
||||
hexchat_get_context (hexchat_plugin *ph);
|
||||
|
||||
const char *
|
||||
hexchat_get_info (hexchat_plugin *ph,
|
||||
const char *id);
|
||||
|
||||
int
|
||||
hexchat_get_prefs (hexchat_plugin *ph,
|
||||
const char *name,
|
||||
const char **string,
|
||||
int *integer);
|
||||
|
||||
hexchat_list *
|
||||
hexchat_list_get (hexchat_plugin *ph,
|
||||
const char *name);
|
||||
|
||||
void
|
||||
hexchat_list_free (hexchat_plugin *ph,
|
||||
hexchat_list *xlist);
|
||||
|
||||
const char * const *
|
||||
hexchat_list_fields (hexchat_plugin *ph,
|
||||
const char *name);
|
||||
|
||||
int
|
||||
hexchat_list_next (hexchat_plugin *ph,
|
||||
hexchat_list *xlist);
|
||||
|
||||
const char *
|
||||
hexchat_list_str (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
|
||||
int
|
||||
hexchat_list_int (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
|
||||
time_t
|
||||
hexchat_list_time (hexchat_plugin *ph,
|
||||
hexchat_list *xlist,
|
||||
const char *name);
|
||||
|
||||
void *
|
||||
hexchat_plugingui_add (hexchat_plugin *ph,
|
||||
const char *filename,
|
||||
const char *name,
|
||||
const char *desc,
|
||||
const char *version,
|
||||
char *reserved);
|
||||
|
||||
void
|
||||
hexchat_plugingui_remove (hexchat_plugin *ph,
|
||||
void *handle);
|
||||
|
||||
int
|
||||
hexchat_emit_print (hexchat_plugin *ph,
|
||||
const char *event_name, ...);
|
||||
|
||||
char *
|
||||
hexchat_gettext (hexchat_plugin *ph,
|
||||
const char *msgid);
|
||||
|
||||
void
|
||||
hexchat_send_modes (hexchat_plugin *ph,
|
||||
const char **targets,
|
||||
int ntargets,
|
||||
int modes_per_line,
|
||||
char sign,
|
||||
char mode);
|
||||
|
||||
char *
|
||||
hexchat_strip (hexchat_plugin *ph,
|
||||
const char *str,
|
||||
int len,
|
||||
int flags);
|
||||
|
||||
void
|
||||
hexchat_free (hexchat_plugin *ph,
|
||||
void *ptr);
|
||||
|
||||
#if !defined(PLUGIN_C) && defined(WIN32)
|
||||
#ifndef HEXCHAT_PLUGIN_HANDLE
|
||||
#define HEXCHAT_PLUGIN_HANDLE (ph)
|
||||
#endif
|
||||
#define hexchat_hook_command ((HEXCHAT_PLUGIN_HANDLE)->hexchat_hook_command)
|
||||
#define hexchat_hook_server ((HEXCHAT_PLUGIN_HANDLE)->hexchat_hook_server)
|
||||
#define hexchat_hook_print ((HEXCHAT_PLUGIN_HANDLE)->hexchat_hook_print)
|
||||
#define hexchat_hook_timer ((HEXCHAT_PLUGIN_HANDLE)->hexchat_hook_timer)
|
||||
#define hexchat_hook_fd ((HEXCHAT_PLUGIN_HANDLE)->hexchat_hook_fd)
|
||||
#define hexchat_unhook ((HEXCHAT_PLUGIN_HANDLE)->hexchat_unhook)
|
||||
#define hexchat_print ((HEXCHAT_PLUGIN_HANDLE)->hexchat_print)
|
||||
#define hexchat_printf ((HEXCHAT_PLUGIN_HANDLE)->hexchat_printf)
|
||||
#define hexchat_command ((HEXCHAT_PLUGIN_HANDLE)->hexchat_command)
|
||||
#define hexchat_commandf ((HEXCHAT_PLUGIN_HANDLE)->hexchat_commandf)
|
||||
#define hexchat_nickcmp ((HEXCHAT_PLUGIN_HANDLE)->hexchat_nickcmp)
|
||||
#define hexchat_set_context ((HEXCHAT_PLUGIN_HANDLE)->hexchat_set_context)
|
||||
#define hexchat_find_context ((HEXCHAT_PLUGIN_HANDLE)->hexchat_find_context)
|
||||
#define hexchat_get_context ((HEXCHAT_PLUGIN_HANDLE)->hexchat_get_context)
|
||||
#define hexchat_get_info ((HEXCHAT_PLUGIN_HANDLE)->hexchat_get_info)
|
||||
#define hexchat_get_prefs ((HEXCHAT_PLUGIN_HANDLE)->hexchat_get_prefs)
|
||||
#define hexchat_list_get ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_get)
|
||||
#define hexchat_list_free ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_free)
|
||||
#define hexchat_list_fields ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_fields)
|
||||
#define hexchat_list_str ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_str)
|
||||
#define hexchat_list_int ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_int)
|
||||
#define hexchat_list_time ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_time)
|
||||
#define hexchat_list_next ((HEXCHAT_PLUGIN_HANDLE)->hexchat_list_next)
|
||||
#define hexchat_plugingui_add ((HEXCHAT_PLUGIN_HANDLE)->hexchat_plugingui_add)
|
||||
#define hexchat_plugingui_remove ((HEXCHAT_PLUGIN_HANDLE)->hexchat_plugingui_remove)
|
||||
#define hexchat_emit_print ((HEXCHAT_PLUGIN_HANDLE)->hexchat_emit_print)
|
||||
#define hexchat_gettext ((HEXCHAT_PLUGIN_HANDLE)->hexchat_gettext)
|
||||
#define hexchat_send_modes ((HEXCHAT_PLUGIN_HANDLE)->hexchat_send_modes)
|
||||
#define hexchat_strip ((HEXCHAT_PLUGIN_HANDLE)->hexchat_strip)
|
||||
#define hexchat_free ((HEXCHAT_PLUGIN_HANDLE)->hexchat_free)
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/******************************************************************
|
||||
* Globals
|
||||
******************************************************************/
|
||||
extern hexchat_plugin *ph;
|
||||
|
||||
/******************************************************************
|
||||
* Prototypes
|
||||
******************************************************************/
|
||||
void wmpaCommands(void);
|
||||
int wmpaAuto(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaCurr(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaFind(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaList(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaNext(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaPlay(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaPause(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaPrev(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaSong(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaStop(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaVolume(char *word[], char *word_eol[], void *user_data);
|
||||
int wmpaHelp(char *word[], char *word_eol[], void *user_data);
|
||||
BOOL wmpaRestoreSettings(void);
|
||||
BOOL wmpaSaveSettings(void);
|
||||
CString wmpaGetSongTitle(void);
|
||||
BOOL SaveSetting(LPCTSTR name, DWORD type, CONST BYTE *value, DWORD size);
|
||||
BOOL GetSetting(LPCTSTR name, DWORD *type, LPBYTE value, DWORD *size);
|
||||
|
||||
#endif /* HEXCHAT_PLUGIN_H */
|
||||
|
@ -1,13 +0,0 @@
|
||||
//
|
||||
// WMPA.RC2 - resources Microsoft Visual C++ does not edit directly
|
||||
//
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#error this file is not editable by Microsoft Visual C++
|
||||
#endif //APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Add manually edited resources here...
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
@ -1,22 +0,0 @@
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Developer Studio generated include file.
|
||||
// Used by wmpa.rc
|
||||
//
|
||||
#define IDD_WMPADIALOG 2000
|
||||
#define IDC_PLAYLIST 2001
|
||||
#define IDC_STATIC1 2002
|
||||
#define IDC_WMP 2005
|
||||
#define IDI_XCHAT 2005
|
||||
#define IDC_SONGLIST 2006
|
||||
#define IDC_STATIC2 2007
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 2006
|
||||
#define _APS_NEXT_COMMAND_VALUE 32771
|
||||
#define _APS_NEXT_CONTROL_VALUE 2008
|
||||
#define _APS_NEXT_SYMED_VALUE 2000
|
||||
#endif
|
||||
#endif
|
@ -1,212 +0,0 @@
|
||||
/******************************************************************
|
||||
* $Id$
|
||||
*
|
||||
* $Log$
|
||||
*
|
||||
* Copyright <20> 2005 David Cullen, All rights reserved
|
||||
*
|
||||
******************************************************************/
|
||||
#include "stdafx.h"
|
||||
#include "wmpa.h"
|
||||
#include "WMPADialog.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
//
|
||||
// Note!
|
||||
//
|
||||
// If this DLL is dynamically linked against the MFC
|
||||
// DLLs, any functions exported from this DLL which
|
||||
// call into MFC must have the AFX_MANAGE_STATE macro
|
||||
// added at the very beginning of the function.
|
||||
//
|
||||
// For example:
|
||||
//
|
||||
// extern "C" BOOL PASCAL EXPORT ExportedFunction()
|
||||
// {
|
||||
// AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
// // normal function body here
|
||||
// }
|
||||
//
|
||||
// It is very important that this macro appear in each
|
||||
// function, prior to any calls into MFC. This means that
|
||||
// it must appear as the first statement within the
|
||||
// function, even before any object variable declarations
|
||||
// as their constructors may generate calls into the MFC
|
||||
// DLL.
|
||||
//
|
||||
// Please see MFC Technical Notes 33 and 58 for additional
|
||||
// details.
|
||||
//
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWmpaApp
|
||||
|
||||
BEGIN_MESSAGE_MAP(CWmpaApp, CWinApp)
|
||||
//{{AFX_MSG_MAP(CWmpaApp)
|
||||
// NOTE - the ClassWizard will add and remove mapping macros here.
|
||||
// DO NOT EDIT what you see in these blocks of generated code!
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWmpaApp construction
|
||||
|
||||
CWmpaApp::CWmpaApp()
|
||||
{
|
||||
// TODO: add construction code here,
|
||||
// Place all significant initialization in InitInstance
|
||||
m_pDialog = NULL;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// The one and only CWmpaApp object
|
||||
|
||||
CWmpaApp theApp;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWmpaApp initialization
|
||||
|
||||
BOOL CWmpaApp::InitInstance()
|
||||
{
|
||||
// Register all OLE server (factories) as running. This enables the
|
||||
// OLE libraries to create objects from other applications.
|
||||
COleObjectFactory::RegisterAll();
|
||||
|
||||
// WARNING: This function enables the ActiveX control container
|
||||
// Without this function you will not be able to load the WMP
|
||||
// In fact you will get the following error:
|
||||
// >>> If this dialog has OLE controls:
|
||||
// >>> AfxEnableControlContainer has not been called yet.
|
||||
// >>> You should call it in your app's InitInstance function.
|
||||
AfxEnableControlContainer();
|
||||
|
||||
// WARNING: This function initializes the COM library for use
|
||||
// Without this function you will not be able to load the WMP
|
||||
// In fact you will get the following error:
|
||||
// CoCreateInstance of OLE control {6BF52A52-394A-11D3-B153-00C04F79FAA6} failed.
|
||||
// >>> Result code: 0x800401f0
|
||||
// >>> Is the control is properly registered?
|
||||
// The Error Lookup tool will tell you result code 0x800401F0 means
|
||||
// CoInitialize has not been called.
|
||||
CoInitialize(NULL);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* ShowWMPA
|
||||
******************************************************************/
|
||||
BOOL CWmpaApp::ShowWMPA(void)
|
||||
{
|
||||
HRESULT result = FALSE;
|
||||
BOOL created;
|
||||
|
||||
// WARNING: The following two funcions make sure we look for
|
||||
// our resources in our DLL not in the calling EXE
|
||||
// Without these functions you will not be able to load the
|
||||
// Windows Media Player
|
||||
HMODULE hModule = GetModuleHandle("WMPA.DLL");
|
||||
AfxSetResourceHandle((HINSTANCE) hModule);
|
||||
|
||||
if (m_pDialog == NULL) m_pDialog = new CWMPADialog;
|
||||
|
||||
created = m_pDialog->Create(IDD_WMPADIALOG, m_pDialog);
|
||||
if (!created) return(E_FAIL);
|
||||
m_pDialog->m_hIcon = LoadIcon(IDI_XCHAT);
|
||||
m_pDialog->SetIcon(m_pDialog->m_hIcon, TRUE);
|
||||
|
||||
result = m_pDialog->ShowWindow(SW_SHOWNORMAL);
|
||||
|
||||
return(created);
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Special entry points required for inproc servers
|
||||
|
||||
STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
return AfxDllGetClassObject(rclsid, riid, ppv);
|
||||
}
|
||||
|
||||
STDAPI DllCanUnloadNow(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
return AfxDllCanUnloadNow();
|
||||
}
|
||||
|
||||
// by exporting DllRegisterServer, you can use regsvr.exe
|
||||
STDAPI DllRegisterServer(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
COleObjectFactory::UpdateRegistryAll();
|
||||
return(S_OK);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* DestroyWMPA
|
||||
******************************************************************/
|
||||
BOOL CWmpaApp::DestroyWMPA(void)
|
||||
{
|
||||
if (theApp.m_pDialog == NULL) return(FALSE);
|
||||
|
||||
theApp.m_pDialog->m_WMP.GetControls().stop();
|
||||
theApp.m_pDialog->DeleteTrayIcon();
|
||||
theApp.m_pDialog->DestroyWindow();
|
||||
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* StartWindowsMediaPlayer
|
||||
******************************************************************/
|
||||
BOOL StartWindowsMediaPlayer(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
|
||||
BOOL result = theApp.ShowWMPA();
|
||||
|
||||
return(result);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* StopWindowsMediaPlayer
|
||||
******************************************************************/
|
||||
BOOL StopWindowsMediaPlayer(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
|
||||
BOOL result = theApp.DestroyWMPA();
|
||||
|
||||
return(result);
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* GetWindowsMediaPlayer
|
||||
******************************************************************/
|
||||
CWMPPlayer4 *GetWindowsMediaPlayer(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
|
||||
if (theApp.m_pDialog == NULL) return(NULL);
|
||||
|
||||
return(&(theApp.m_pDialog->m_WMP));
|
||||
}
|
||||
|
||||
/******************************************************************
|
||||
* GetWMPADialog
|
||||
******************************************************************/
|
||||
CWMPADialog *GetWMPADialog(void)
|
||||
{
|
||||
AFX_MANAGE_STATE(AfxGetStaticModuleState());
|
||||
|
||||
if (theApp.m_pDialog == NULL) return(NULL);
|
||||
|
||||
return(theApp.m_pDialog);
|
||||
}
|
||||
|
@ -1,15 +0,0 @@
|
||||
; wmpa.def : Declares the module parameters for the DLL.
|
||||
|
||||
LIBRARY "hcwmpa"
|
||||
|
||||
EXPORTS
|
||||
; Explicit exports can go here
|
||||
DllCanUnloadNow PRIVATE
|
||||
DllGetClassObject PRIVATE
|
||||
DllRegisterServer PRIVATE
|
||||
hexchat_plugin_init
|
||||
hexchat_plugin_deinit
|
||||
hexchat_plugin_get_info
|
||||
StartWindowsMediaPlayer
|
||||
GetWindowsMediaPlayer
|
||||
GetWMPADialog
|
@ -1,61 +0,0 @@
|
||||
/******************************************************************
|
||||
* $Id$
|
||||
*
|
||||
* $Log$
|
||||
*
|
||||
* Copyright <20> 2005 David Cullen, All rights reserved
|
||||
*
|
||||
******************************************************************/
|
||||
#if !defined(AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_)
|
||||
#define AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
#ifndef __AFXWIN_H__
|
||||
#error include 'stdafx.h' before including this file for PCH
|
||||
#endif
|
||||
|
||||
#include "resource.h" // main symbols
|
||||
#include "WMPADialog.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWmpaApp
|
||||
// See wmpa.cpp for the implementation of this class
|
||||
//
|
||||
|
||||
class CWmpaApp : public CWinApp
|
||||
{
|
||||
public:
|
||||
CWmpaApp();
|
||||
|
||||
BOOL ShowWMPA(void);
|
||||
BOOL DestroyWMPA(void);
|
||||
|
||||
CWMPADialog *m_pDialog;
|
||||
// Overrides
|
||||
// ClassWizard generated virtual function overrides
|
||||
//{{AFX_VIRTUAL(CWmpaApp)
|
||||
public:
|
||||
virtual BOOL InitInstance();
|
||||
//}}AFX_VIRTUAL
|
||||
|
||||
//{{AFX_MSG(CWmpaApp)
|
||||
// NOTE - the ClassWizard will add and remove member functions here.
|
||||
// DO NOT EDIT what you see in these blocks of generated code !
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
};
|
||||
|
||||
BOOL StartWindowsMediaPlayer(void);
|
||||
BOOL StopWindowsMediaPlayer(void);
|
||||
CWMPPlayer4 *GetWindowsMediaPlayer(void);
|
||||
CWMPADialog *GetWMPADialog(void);
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_)
|
Binary file not shown.
Before Width: | Height: | Size: 4.2 KiB |
@ -1,44 +0,0 @@
|
||||
// wmpa.odl : type library source for wmpa.dll
|
||||
|
||||
// This file will be processed by the MIDL compiler to produce the
|
||||
// type library (wmpa.tlb).
|
||||
|
||||
[ uuid(2D225385-EFD3-4DD8-9377-A7F244C522D0), version(1.0) ]
|
||||
library Wmpa
|
||||
{
|
||||
importlib("stdole32.tlb");
|
||||
importlib("stdole2.tlb");
|
||||
|
||||
|
||||
|
||||
|
||||
// Primary dispatch interface for CWMPADIALOG
|
||||
|
||||
[ uuid(01C1B3AA-C7FC-4023-89A5-C814E1B62B9B) ]
|
||||
dispinterface IWMPADIALOG
|
||||
{
|
||||
properties:
|
||||
// NOTE - ClassWizard will maintain property information here.
|
||||
// Use extreme caution when editing this section.
|
||||
//{{AFX_ODL_PROP(CWMPADIALOG)
|
||||
//}}AFX_ODL_PROP
|
||||
|
||||
methods:
|
||||
// NOTE - ClassWizard will maintain method information here.
|
||||
// Use extreme caution when editing this section.
|
||||
//{{AFX_ODL_METHOD(CWMPADIALOG)
|
||||
//}}AFX_ODL_METHOD
|
||||
|
||||
};
|
||||
|
||||
// Class information for CWMPADIALOG
|
||||
|
||||
[ uuid(9007B1B4-0006-453D-A799-DB8CBA1AE22A) ]
|
||||
coclass WMPADIALOG
|
||||
{
|
||||
[default] dispinterface IWMPADIALOG;
|
||||
};
|
||||
|
||||
//{{AFX_APPEND_ODL}}
|
||||
//}}AFX_APPEND_ODL}}
|
||||
};
|
@ -1,207 +0,0 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// English (U.S.) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
|
||||
"#define _AFX_NO_OLE_RESOURCES\r\n"
|
||||
"#define _AFX_NO_TRACKER_RESOURCES\r\n"
|
||||
"#define _AFX_NO_PROPERTY_RESOURCES\r\n"
|
||||
"\r\n"
|
||||
"#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n"
|
||||
"#ifdef _WIN32\r\n"
|
||||
"LANGUAGE 9, 1\r\n"
|
||||
"#pragma code_page(1252)\r\n"
|
||||
"#endif //_WIN32\r\n"
|
||||
"#include ""res\\wmpa.rc2"" // non-Microsoft Visual C++ edited resources\r\n"
|
||||
"#include ""afxres.rc"" // Standard components\r\n"
|
||||
"#endif\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 1,0,0,1
|
||||
PRODUCTVERSION 1,0,0,1
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x4L
|
||||
FILETYPE 0x2L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904B0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "\0"
|
||||
VALUE "FileDescription", "wmpa DLL\0"
|
||||
VALUE "FileVersion", "1, 0, 0, 1\0"
|
||||
VALUE "InternalName", "wmpa\0"
|
||||
VALUE "LegalCopyright", "Copyright (C) 2005\0"
|
||||
VALUE "LegalTrademarks", "\0"
|
||||
VALUE "OriginalFilename", "wmpa.DLL\0"
|
||||
VALUE "ProductName", "wmpa Dynamic Link Library\0"
|
||||
VALUE "ProductVersion", "1, 0, 0, 1\0"
|
||||
VALUE "OLESelfRegister", "\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Dialog
|
||||
//
|
||||
|
||||
IDD_WMPADIALOG DIALOG DISCARDABLE 0, 0, 317, 236
|
||||
STYLE DS_MODALFRAME | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "Unitialized"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
LISTBOX IDC_PLAYLIST,165,15,145,145,LBS_NOINTEGRALHEIGHT |
|
||||
WS_VSCROLL | WS_HSCROLL | WS_TABSTOP
|
||||
LTEXT "Play Lists (Double-click to play)",IDC_STATIC1,165,5,
|
||||
145,10
|
||||
CONTROL "",IDC_WMP,"{6BF52A52-394A-11D3-B153-00C04F79FAA6}",
|
||||
WS_TABSTOP,5,5,155,155
|
||||
LISTBOX IDC_SONGLIST,5,175,305,55,LBS_NOINTEGRALHEIGHT |
|
||||
WS_VSCROLL | WS_TABSTOP
|
||||
LTEXT "Song List (Double-click to play)",IDC_STATIC2,5,165,305,
|
||||
10
|
||||
END
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DESIGNINFO
|
||||
//
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
GUIDELINES DESIGNINFO DISCARDABLE
|
||||
BEGIN
|
||||
IDD_WMPADIALOG, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 310
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 229
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Dialog Info
|
||||
//
|
||||
|
||||
IDD_WMPADIALOG DLGINIT
|
||||
BEGIN
|
||||
IDC_WMP, 0x376, 166, 0
|
||||
0x0000, 0x0000, 0x0300, 0x0000, 0x0008, 0x0000, 0x0000, 0x0005, 0x0000,
|
||||
0x0000, 0x0000, 0x3ff0, 0x0003, 0x0000, 0x0000, 0x0005, 0x0000, 0x0000,
|
||||
0x0000, 0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x0003, 0x0001, 0x0000,
|
||||
0x000b, 0xffff, 0x0003, 0x0000, 0x0000, 0x000b, 0xffff, 0x0008, 0x0002,
|
||||
0x0000, 0x0000, 0x0003, 0x0032, 0x0000, 0x000b, 0x0000, 0x0008, 0x000a,
|
||||
0x0000, 0x0066, 0x0075, 0x006c, 0x006c, 0x0000, 0x000b, 0x0000, 0x000b,
|
||||
0x0000, 0x000b, 0xffff, 0x000b, 0xffff, 0x000b, 0x0000, 0x0008, 0x0002,
|
||||
0x0000, 0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x0008, 0x0002, 0x0000,
|
||||
0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x000b, 0x0000, 0x1815, 0x0000,
|
||||
0x1a0c, 0x0000,
|
||||
0
|
||||
END
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Icon
|
||||
//
|
||||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
//
|
||||
// the WMP icon comes from here:
|
||||
// http://www.iconarchive.com/show/phuzion-icons-by-kyo-tux/Applic-WMP-icon.html
|
||||
IDI_XCHAT ICON DISCARDABLE "wmpa.ico"
|
||||
#endif // English (U.S.) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
#define _AFX_NO_SPLITTER_RESOURCES
|
||||
#define _AFX_NO_OLE_RESOURCES
|
||||
#define _AFX_NO_TRACKER_RESOURCES
|
||||
#define _AFX_NO_PROPERTY_RESOURCES
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE 9, 1
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
#include "res\wmpa.rc2" // non-Microsoft Visual C++ edited resources
|
||||
#include "afxres.rc" // Standard components
|
||||
#endif
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
@ -1,20 +0,0 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 11.00
|
||||
# Visual Studio 2010
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wmpa", "wmpa.vcxproj", "{08AD7C4D-DDDC-9545-A8D7-1808E6056143}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Release|Win32 = Release|Win32
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|Win32.Build.0 = Release|Win32
|
||||
{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|x64.ActiveCfg = Release|x64
|
||||
{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
@ -1,160 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>wmpa</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\..\win32\hexchat.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\..\win32\hexchat.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>hcwmpa</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<TargetName>hcwmpa</TargetName>
|
||||
<OutDir>$(HexChatBin)</OutDir>
|
||||
<IntDir>$(HexChatObj)$(ProjectName)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;WMPA_EXPORTS;_AFXDLL;_AFX_NO_DAO_SUPPORT;_WIN32_WINNT=0x0501;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MultiProcessorCompilation>false</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ModuleDefinitionFile>wmpa.def</ModuleDefinitionFile>
|
||||
</Link>
|
||||
<Midl>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
</Midl>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;_WIN64;_AMD64_;NDEBUG;_WINDOWS;_USRDLL;WMPA_EXPORTS;_AFXDLL;_AFX_NO_DAO_SUPPORT;_WIN32_WINNT=0x0501;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MultiProcessorCompilation>false</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ModuleDefinitionFile>wmpa.def</ModuleDefinitionFile>
|
||||
</Link>
|
||||
<Midl>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
</Midl>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="StdAfx.cpp" />
|
||||
<ClCompile Include="wmpa.cpp" />
|
||||
<ClCompile Include="wmpadialog.cpp" />
|
||||
<ClCompile Include="wmpcdrom.cpp" />
|
||||
<ClCompile Include="wmpcdromcollection.cpp" />
|
||||
<ClCompile Include="wmpclosedcaption.cpp" />
|
||||
<ClCompile Include="wmpcontrols.cpp" />
|
||||
<ClCompile Include="wmpdvd.cpp" />
|
||||
<ClCompile Include="wmperror.cpp" />
|
||||
<ClCompile Include="wmperroritem.cpp" />
|
||||
<ClCompile Include="wmpmedia.cpp" />
|
||||
<ClCompile Include="wmpmediacollection.cpp" />
|
||||
<ClCompile Include="wmpnetwork.cpp" />
|
||||
<ClCompile Include="wmpplayer4.cpp" />
|
||||
<ClCompile Include="wmpplayerapplication.cpp" />
|
||||
<ClCompile Include="wmpplaylist.cpp" />
|
||||
<ClCompile Include="wmpplaylistarray.cpp" />
|
||||
<ClCompile Include="wmpplaylistcollection.cpp" />
|
||||
<ClCompile Include="wmpsettings.cpp" />
|
||||
<ClCompile Include="wmpstringcollection.cpp" />
|
||||
<ClCompile Include="hexchat-plugin.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="resource.h" />
|
||||
<ClInclude Include="StdAfx.h" />
|
||||
<ClInclude Include="wmpa.h" />
|
||||
<ClInclude Include="wmpadialog.h" />
|
||||
<ClInclude Include="wmpcdrom.h" />
|
||||
<ClInclude Include="wmpcdromcollection.h" />
|
||||
<ClInclude Include="wmpclosedcaption.h" />
|
||||
<ClInclude Include="wmpcontrols.h" />
|
||||
<ClInclude Include="wmpdvd.h" />
|
||||
<ClInclude Include="wmperror.h" />
|
||||
<ClInclude Include="wmperroritem.h" />
|
||||
<ClInclude Include="wmpmedia.h" />
|
||||
<ClInclude Include="wmpmediacollection.h" />
|
||||
<ClInclude Include="wmpnetwork.h" />
|
||||
<ClInclude Include="wmpplayer4.h" />
|
||||
<ClInclude Include="wmpplayerapplication.h" />
|
||||
<ClInclude Include="wmpplaylist.h" />
|
||||
<ClInclude Include="wmpplaylistarray.h" />
|
||||
<ClInclude Include="wmpplaylistcollection.h" />
|
||||
<ClInclude Include="wmpsettings.h" />
|
||||
<ClInclude Include="wmpstringcollection.h" />
|
||||
<ClInclude Include="hexchat-plugin.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="ReadMe.txt" />
|
||||
<None Include="res\wmpa.rc2" />
|
||||
<None Include="wmpa.aps" />
|
||||
<None Include="wmpa.def" />
|
||||
<None Include="wmpa.ico" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Midl Include="wmpa.odl" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="wmpa.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
@ -1,180 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files">
|
||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files\res">
|
||||
<UniqueIdentifier>{c54ddc93-06ab-4a74-854a-9ec976b7bfd0}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="StdAfx.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpa.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpadialog.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpcdrom.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpcdromcollection.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpclosedcaption.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpcontrols.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpdvd.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmperror.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmperroritem.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpmedia.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpmediacollection.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpnetwork.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpplayer4.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpplayerapplication.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpplaylist.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpplaylistarray.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpplaylistcollection.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpsettings.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="wmpstringcollection.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hexchat-plugin.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="resource.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="StdAfx.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpa.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpadialog.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpcdrom.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpcdromcollection.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpclosedcaption.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpcontrols.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpdvd.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmperror.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmperroritem.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpmedia.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpmediacollection.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpnetwork.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpplayer4.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpplayerapplication.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpplaylist.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpplaylistarray.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpplaylistcollection.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpsettings.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="wmpstringcollection.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="hexchat-plugin.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="wmpa.aps">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="wmpa.def">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="wmpa.ico">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="ReadMe.txt">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="res\wmpa.rc2">
|
||||
<Filter>Resource Files\res</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Midl Include="wmpa.odl">
|
||||
<Filter>Resource Files</Filter>
|
||||
</Midl>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="wmpa.rc">
|
||||
<Filter>Resource Files</Filter>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
@ -1,375 +0,0 @@
|
||||
/******************************************************************
|
||||
* $Id$
|
||||
*
|
||||
* $Log$
|
||||
*
|
||||
* Copyright <20> 2005 David Cullen, All rights reserved
|
||||
*
|
||||
******************************************************************/
|
||||
#include "stdafx.h"
|
||||
#include "wmpa.h"
|
||||
#include "WMPADialog.h"
|
||||
#include "shellapi.h"
|
||||
#include "hexchat-plugin.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
#define ID_TRAY_ICON 1000
|
||||
#define WM_TRAY_ICON (WM_APP + 1)
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPADialog dialog
|
||||
|
||||
CWMPADialog::CWMPADialog(CWnd* pParent /*=NULL*/)
|
||||
: CDialog(CWMPADialog::IDD, pParent)
|
||||
{
|
||||
EnableAutomation();
|
||||
|
||||
//{{AFX_DATA_INIT(CWMPADialog)
|
||||
//}}AFX_DATA_INIT
|
||||
}
|
||||
|
||||
|
||||
void CWMPADialog::OnFinalRelease()
|
||||
{
|
||||
// When the last reference for an automation object is released
|
||||
// OnFinalRelease is called. The base class will automatically
|
||||
// deletes the object. Add additional cleanup required for your
|
||||
// object before calling the base class.
|
||||
|
||||
CDialog::OnFinalRelease();
|
||||
}
|
||||
|
||||
void CWMPADialog::DoDataExchange(CDataExchange* pDX)
|
||||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(CWMPADialog)
|
||||
DDX_Control(pDX, IDC_SONGLIST, m_SongListBox);
|
||||
DDX_Control(pDX, IDC_PLAYLIST, m_PlaylistBox);
|
||||
DDX_Control(pDX, IDC_WMP, m_WMP);
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
|
||||
BEGIN_MESSAGE_MAP(CWMPADialog, CDialog)
|
||||
//{{AFX_MSG_MAP(CWMPADialog)
|
||||
ON_LBN_DBLCLK(IDC_PLAYLIST, OnDblclkPlaylist)
|
||||
ON_WM_SHOWWINDOW()
|
||||
ON_WM_CLOSE()
|
||||
ON_LBN_DBLCLK(IDC_SONGLIST, OnDblclkSonglist)
|
||||
ON_WM_DESTROY()
|
||||
ON_WM_SIZE()
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
BEGIN_DISPATCH_MAP(CWMPADialog, CDialog)
|
||||
//{{AFX_DISPATCH_MAP(CWMPADialog)
|
||||
// NOTE - the ClassWizard will add and remove mapping macros here.
|
||||
//}}AFX_DISPATCH_MAP
|
||||
END_DISPATCH_MAP()
|
||||
|
||||
// Note: we add support for IID_IWMPADialog to support typesafe binding
|
||||
// from VBA. This IID must match the GUID that is attached to the
|
||||
// dispinterface in the .ODL file.
|
||||
|
||||
// {01C1B3AA-C7FC-4023-89A5-C814E1B62B9B}
|
||||
static const IID IID_IWMPADialog =
|
||||
{ 0x1c1b3aa, 0xc7fc, 0x4023, { 0x89, 0xa5, 0xc8, 0x14, 0xe1, 0xb6, 0x2b, 0x9b } };
|
||||
|
||||
BEGIN_INTERFACE_MAP(CWMPADialog, CDialog)
|
||||
INTERFACE_PART(CWMPADialog, IID_IWMPADialog, Dispatch)
|
||||
END_INTERFACE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPADialog message handlers
|
||||
|
||||
void CWMPADialog::OnDblclkPlaylist()
|
||||
{
|
||||
// TODO: Add your control notification handler code here
|
||||
long index;
|
||||
|
||||
// Get the playlist name
|
||||
index = m_PlaylistBox.GetCurSel();
|
||||
CString playlistName;
|
||||
m_PlaylistBox.GetText(index, playlistName);
|
||||
|
||||
// Get the playlist
|
||||
CWMPPlaylistCollection pc = m_WMP.GetPlaylistCollection();
|
||||
CWMPPlaylistArray pa = pc.getByName((LPCTSTR) playlistName);
|
||||
CWMPPlaylist playlist = pa.Item(0);
|
||||
m_WMP.SetCurrentPlaylist(playlist);
|
||||
|
||||
// Set the song list
|
||||
UpdateSongList();
|
||||
|
||||
m_WMP.GetControls().play();
|
||||
if (autoAnnounce) {
|
||||
hexchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
else {
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
}
|
||||
|
||||
void CWMPADialog::OnShowWindow(BOOL bShow, UINT nStatus)
|
||||
{
|
||||
CDialog::OnShowWindow(bShow, nStatus);
|
||||
|
||||
// TODO: Add your message handler code here
|
||||
if (bShow) {
|
||||
if (!trayInit) {
|
||||
ZeroMemory(&nid, sizeof(nid));
|
||||
nid.cbSize = sizeof(nid);
|
||||
nid.hWnd = m_hWnd;
|
||||
nid.uID = ID_TRAY_ICON;
|
||||
nid.uFlags = NIF_ICON | NIF_MESSAGE | NIF_TIP;
|
||||
nid.uCallbackMessage = WM_TRAY_ICON;
|
||||
nid.hIcon = m_hIcon;
|
||||
strcpy(nid.szTip, "WMPA");
|
||||
strcat(nid.szTip, VER_STRING);
|
||||
strcat(nid.szTip, "\nWindows Media\nPlayer Announcer");
|
||||
nid.dwState = 0;
|
||||
nid.dwStateMask = 0;
|
||||
strcpy(nid.szInfo, "WMPA ");
|
||||
strcat(nid.szInfo, VER_STRING);
|
||||
nid.uTimeout = 10000; // 10 second time out
|
||||
strcat(nid.szInfoTitle, "WMPA");
|
||||
nid.dwInfoFlags = 0;
|
||||
trayInit = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
void CWMPADialog::PostNcDestroy()
|
||||
{
|
||||
// TODO: Add your specialized code here and/or call the base class
|
||||
delete this;
|
||||
|
||||
CDialog::PostNcDestroy();
|
||||
}
|
||||
|
||||
|
||||
BOOL CWMPADialog::OnInitDialog()
|
||||
{
|
||||
CDialog::OnInitDialog();
|
||||
|
||||
CString title = "WMPA";
|
||||
title += " ";
|
||||
title += VER_STRING;
|
||||
SetWindowText((LPCTSTR) title);
|
||||
|
||||
UpdatePlayLists();
|
||||
|
||||
autoAnnounce = FALSE;
|
||||
trayInit = FALSE;
|
||||
trayClicked = FALSE;
|
||||
|
||||
return TRUE; // return TRUE unless you set the focus to a control
|
||||
// EXCEPTION: OCX Property Pages should return FALSE
|
||||
}
|
||||
|
||||
void CWMPADialog::OnClose()
|
||||
{
|
||||
// TODO: Add your message handler code here and/or call default
|
||||
Shell_NotifyIcon(NIM_ADD, &nid);
|
||||
ShowWindow(SW_HIDE);
|
||||
|
||||
// Don't let the user close the dialog
|
||||
// CDialog::OnClose();
|
||||
}
|
||||
|
||||
void CWMPADialog::OnCancel()
|
||||
{
|
||||
// this->DestroyWindow();
|
||||
}
|
||||
|
||||
void CWMPADialog::OnDblclkSonglist()
|
||||
{
|
||||
// TODO: Add your control notification handler code here
|
||||
int index = m_SongListBox.GetCurSel();
|
||||
m_WMP.GetControls().playItem(m_WMP.GetCurrentPlaylist().GetItem(index));
|
||||
if (autoAnnounce) {
|
||||
hexchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
else {
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
}
|
||||
|
||||
BEGIN_EVENTSINK_MAP(CWMPADialog, CDialog)
|
||||
//{{AFX_EVENTSINK_MAP(CWMPADialog)
|
||||
ON_EVENT(CWMPADialog, IDC_WMP, 5806 /* CurrentItemChange */, OnCurrentItemChangeWmp, VTS_DISPATCH)
|
||||
ON_EVENT(CWMPADialog, IDC_WMP, 5101 /* PlayStateChange */, OnPlayStateChangeWmp, VTS_I4)
|
||||
//}}AFX_EVENTSINK_MAP
|
||||
END_EVENTSINK_MAP()
|
||||
|
||||
void CWMPADialog::OnCurrentItemChangeWmp(LPDISPATCH pdispMedia)
|
||||
{
|
||||
// TODO: Add your control notification handler code here
|
||||
|
||||
int state = m_WMP.GetPlayState();
|
||||
if (state == 3) { // Playing
|
||||
if (autoAnnounce) {
|
||||
hexchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
else {
|
||||
hexchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
|
||||
}
|
||||
}
|
||||
|
||||
SelectCurrentSong();
|
||||
}
|
||||
|
||||
void CWMPADialog::OnDestroy()
|
||||
{
|
||||
CDialog::OnDestroy();
|
||||
|
||||
// TODO: Add your message handler code here
|
||||
}
|
||||
|
||||
void CWMPADialog::UpdateSongList()
|
||||
{
|
||||
char buffer[32];
|
||||
CString name;
|
||||
CString artist;
|
||||
CString title;
|
||||
CString album;
|
||||
CString bitrate;
|
||||
CString duration;
|
||||
CString song;
|
||||
long index;
|
||||
long count;
|
||||
|
||||
m_SongListBox.ResetContent();
|
||||
CWMPPlaylist playlist = m_WMP.GetCurrentPlaylist();
|
||||
count = playlist.GetCount();
|
||||
m_SongListBox.ResetContent();
|
||||
for (index = 0; index < count; index++) {
|
||||
name = playlist.GetItem(index).GetName();
|
||||
artist = playlist.GetItem(index).getItemInfo("Artist");
|
||||
title = playlist.GetItem(index).getItemInfo("Title");
|
||||
album = playlist.GetItem(index).getItemInfo("Album");
|
||||
bitrate = playlist.GetItem(index).getItemInfo("Bitrate");
|
||||
duration = playlist.GetItem(index).GetDurationString();
|
||||
|
||||
long krate = strtoul((LPCTSTR) bitrate, NULL, 10) / 1000;
|
||||
_ultoa(krate, buffer, 10);
|
||||
bitrate = CString(buffer);
|
||||
|
||||
if (album.IsEmpty()) {
|
||||
playlist.removeItem(playlist.GetItem(index));
|
||||
count = playlist.GetCount();
|
||||
}
|
||||
else {
|
||||
song = "";
|
||||
song += artist;
|
||||
if (song.IsEmpty()) song = "Various";
|
||||
song += " - ";
|
||||
song += title;
|
||||
song += " (";
|
||||
song += album;
|
||||
song += ") [";
|
||||
song += duration;
|
||||
song += "/";
|
||||
song += bitrate;
|
||||
song += "Kbps]";
|
||||
m_SongListBox.AddString((LPCTSTR) song);
|
||||
}
|
||||
|
||||
}
|
||||
m_SongListBox.SetCurSel(0);
|
||||
}
|
||||
|
||||
void CWMPADialog::SelectCurrentSong()
|
||||
{
|
||||
CWMPMedia media;
|
||||
long index;
|
||||
long count;
|
||||
|
||||
count = m_WMP.GetCurrentPlaylist().GetCount();
|
||||
for (index = 0; index < count; index++) {
|
||||
media = m_WMP.GetCurrentPlaylist().GetItem(index);
|
||||
if (m_WMP.GetCurrentMedia().GetIsIdentical(media)) {
|
||||
m_SongListBox.SetCurSel(index);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CWMPADialog::UpdatePlayLists()
|
||||
{
|
||||
// TODO: Add extra initialization here
|
||||
CWMPPlaylistCollection pc = m_WMP.GetPlaylistCollection();
|
||||
CWMPPlaylistArray pa = pc.getAll();
|
||||
CWMPPlaylist playlist;
|
||||
|
||||
int index;
|
||||
int count = pa.GetCount();
|
||||
m_PlaylistBox.ResetContent();
|
||||
for (index = 0; index < count; index++) {
|
||||
playlist = pa.Item(index);
|
||||
m_PlaylistBox.AddString((LPCTSTR) playlist.GetName());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void CWMPADialog::OnPlayStateChangeWmp(long NewState)
|
||||
{
|
||||
// TODO: Add your control notification handler code here
|
||||
}
|
||||
|
||||
void CWMPADialog::OnSize(UINT nType, int cx, int cy)
|
||||
{
|
||||
CDialog::OnSize(nType, cx, cy);
|
||||
// TODO: Add your message handler code here
|
||||
switch (nType) {
|
||||
case SIZE_MINIMIZED:
|
||||
break;
|
||||
|
||||
case SIZE_RESTORED:
|
||||
Shell_NotifyIcon(NIM_DELETE, &nid);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
LRESULT CWMPADialog::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
// TODO: Add your specialized code here and/or call the base class
|
||||
switch (message) {
|
||||
case WM_TRAY_ICON:
|
||||
switch (lParam) {
|
||||
case WM_LBUTTONDBLCLK:
|
||||
trayClicked = TRUE;
|
||||
break;
|
||||
|
||||
case WM_LBUTTONUP:
|
||||
if (trayClicked == TRUE) {
|
||||
ShowWindow(SW_RESTORE);
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
trayClicked = FALSE;
|
||||
break;
|
||||
}
|
||||
return(TRUE);
|
||||
break;
|
||||
|
||||
default:
|
||||
return CDialog::WindowProc(message, wParam, lParam);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void CWMPADialog::DeleteTrayIcon()
|
||||
{
|
||||
Shell_NotifyIcon(NIM_DELETE, &nid);
|
||||
}
|
@ -1,91 +0,0 @@
|
||||
/******************************************************************
|
||||
* $Id$
|
||||
*
|
||||
* $Log$
|
||||
*
|
||||
* Copyright <20> 2005 David Cullen, All rights reserved
|
||||
*
|
||||
******************************************************************/
|
||||
//{{AFX_INCLUDES()
|
||||
#include "wmpplayer4.h"
|
||||
//}}AFX_INCLUDES
|
||||
#if !defined(AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_)
|
||||
#define AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// WMPADialog.h : header file
|
||||
//
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPADialog dialog
|
||||
|
||||
class CWMPADialog : public CDialog
|
||||
{
|
||||
// Construction
|
||||
public:
|
||||
CWMPADialog(CWnd* pParent = NULL); // standard constructor
|
||||
virtual void OnCancel();
|
||||
void UpdatePlayLists();
|
||||
void UpdateSongList();
|
||||
void SelectCurrentSong();
|
||||
void DeleteTrayIcon();
|
||||
BOOL autoAnnounce;
|
||||
HICON m_hIcon;
|
||||
|
||||
private:
|
||||
BOOL trayInit;
|
||||
BOOL trayClicked;
|
||||
NOTIFYICONDATA nid;
|
||||
|
||||
public:
|
||||
// Dialog Data
|
||||
//{{AFX_DATA(CWMPADialog)
|
||||
enum { IDD = IDD_WMPADIALOG };
|
||||
CListBox m_SongListBox;
|
||||
CListBox m_PlaylistBox;
|
||||
CWMPPlayer4 m_WMP;
|
||||
//}}AFX_DATA
|
||||
|
||||
|
||||
// Overrides
|
||||
// ClassWizard generated virtual function overrides
|
||||
//{{AFX_VIRTUAL(CWMPADialog)
|
||||
public:
|
||||
virtual void OnFinalRelease();
|
||||
protected:
|
||||
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
|
||||
virtual void PostNcDestroy();
|
||||
virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
//}}AFX_VIRTUAL
|
||||
|
||||
// Implementation
|
||||
protected:
|
||||
|
||||
// Generated message map functions
|
||||
//{{AFX_MSG(CWMPADialog)
|
||||
afx_msg void OnDblclkPlaylist();
|
||||
afx_msg void OnShowWindow(BOOL bShow, UINT nStatus);
|
||||
virtual BOOL OnInitDialog();
|
||||
afx_msg void OnClose();
|
||||
afx_msg void OnDblclkSonglist();
|
||||
afx_msg void OnCurrentItemChangeWmp(LPDISPATCH pdispMedia);
|
||||
afx_msg void OnDestroy();
|
||||
afx_msg void OnPlayStateChangeWmp(long NewState);
|
||||
afx_msg void OnSize(UINT nType, int cx, int cy);
|
||||
DECLARE_EVENTSINK_MAP()
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
// Generated OLE dispatch map functions
|
||||
//{{AFX_DISPATCH(CWMPADialog)
|
||||
// NOTE - the ClassWizard will add and remove member functions here.
|
||||
//}}AFX_DISPATCH
|
||||
DECLARE_DISPATCH_MAP()
|
||||
DECLARE_INTERFACE_MAP()
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_)
|
@ -1,37 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpcdrom.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpplaylist.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdrom properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdrom operations
|
||||
|
||||
CString CWMPCdrom::GetDriveSpecifier()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0xfb, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPCdrom::GetPlaylist()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0xfc, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPCdrom::eject()
|
||||
{
|
||||
InvokeHelper(0xfd, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
#if !defined(AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_)
|
||||
#define AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPPlaylist;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdrom wrapper class
|
||||
|
||||
class CWMPCdrom : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPCdrom() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPCdrom(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPCdrom(const CWMPCdrom& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
CString GetDriveSpecifier();
|
||||
CWMPPlaylist GetPlaylist();
|
||||
void eject();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_)
|
@ -1,45 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpcdromcollection.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "WMPCdrom.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdromCollection properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdromCollection operations
|
||||
|
||||
long CWMPCdromCollection::GetCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x12d, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPCdrom CWMPCdromCollection::Item(long lIndex)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x12e, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
lIndex);
|
||||
return CWMPCdrom(pDispatch);
|
||||
}
|
||||
|
||||
CWMPCdrom CWMPCdromCollection::getByDriveSpecifier(LPCTSTR bstrDriveSpecifier)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x12f, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrDriveSpecifier);
|
||||
return CWMPCdrom(pDispatch);
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
#if !defined(AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_)
|
||||
#define AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPCdrom;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPCdromCollection wrapper class
|
||||
|
||||
class CWMPCdromCollection : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPCdromCollection() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPCdromCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPCdromCollection(const CWMPCdromCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetCount();
|
||||
CWMPCdrom Item(long lIndex);
|
||||
CWMPCdrom getByDriveSpecifier(LPCTSTR bstrDriveSpecifier);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_)
|
@ -1,75 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpclosedcaption.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPClosedCaption properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPClosedCaption operations
|
||||
|
||||
CString CWMPClosedCaption::GetSAMIStyle()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x3b7, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPClosedCaption::SetSAMIStyle(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3b7, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
CString CWMPClosedCaption::GetSAMILang()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x3b8, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPClosedCaption::SetSAMILang(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3b8, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
CString CWMPClosedCaption::GetSAMIFileName()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x3b9, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPClosedCaption::SetSAMIFileName(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3b9, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
CString CWMPClosedCaption::GetCaptioningId()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x3ba, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPClosedCaption::SetCaptioningId(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3ba, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
@ -1,40 +0,0 @@
|
||||
#if !defined(AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_)
|
||||
#define AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPClosedCaption wrapper class
|
||||
|
||||
class CWMPClosedCaption : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPClosedCaption() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPClosedCaption(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPClosedCaption(const CWMPClosedCaption& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
CString GetSAMIStyle();
|
||||
void SetSAMIStyle(LPCTSTR lpszNewValue);
|
||||
CString GetSAMILang();
|
||||
void SetSAMILang(LPCTSTR lpszNewValue);
|
||||
CString GetSAMIFileName();
|
||||
void SetSAMIFileName(LPCTSTR lpszNewValue);
|
||||
CString GetCaptioningId();
|
||||
void SetCaptioningId(LPCTSTR lpszNewValue);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_)
|
@ -1,123 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpcontrols.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpmedia.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPControls properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPControls operations
|
||||
|
||||
BOOL CWMPControls::GetIsAvailable(LPCTSTR bstrItem)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3e, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
|
||||
bstrItem);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPControls::play()
|
||||
{
|
||||
InvokeHelper(0x33, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPControls::stop()
|
||||
{
|
||||
InvokeHelper(0x34, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPControls::pause()
|
||||
{
|
||||
InvokeHelper(0x35, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPControls::fastForward()
|
||||
{
|
||||
InvokeHelper(0x36, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPControls::fastReverse()
|
||||
{
|
||||
InvokeHelper(0x37, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
double CWMPControls::GetCurrentPosition()
|
||||
{
|
||||
double result;
|
||||
InvokeHelper(0x38, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPControls::SetCurrentPosition(double newValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_R8;
|
||||
InvokeHelper(0x38, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
newValue);
|
||||
}
|
||||
|
||||
CString CWMPControls::GetCurrentPositionString()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x39, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPControls::next()
|
||||
{
|
||||
InvokeHelper(0x3a, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPControls::previous()
|
||||
{
|
||||
InvokeHelper(0x3b, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
CWMPMedia CWMPControls::GetCurrentItem()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x3c, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPMedia(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPControls::SetCurrentItem(LPDISPATCH newValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x3c, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
newValue);
|
||||
}
|
||||
|
||||
long CWMPControls::GetCurrentMarker()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x3d, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPControls::SetCurrentMarker(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x3d, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
void CWMPControls::playItem(LPDISPATCH pIWMPMedia)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x3f, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pIWMPMedia);
|
||||
}
|
@ -1,52 +0,0 @@
|
||||
#if !defined(AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_)
|
||||
#define AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPMedia;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPControls wrapper class
|
||||
|
||||
class CWMPControls : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPControls() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPControls(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPControls(const CWMPControls& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
BOOL GetIsAvailable(LPCTSTR bstrItem);
|
||||
void play();
|
||||
void stop();
|
||||
void pause();
|
||||
void fastForward();
|
||||
void fastReverse();
|
||||
double GetCurrentPosition();
|
||||
void SetCurrentPosition(double newValue);
|
||||
CString GetCurrentPositionString();
|
||||
void next();
|
||||
void previous();
|
||||
CWMPMedia GetCurrentItem();
|
||||
void SetCurrentItem(LPDISPATCH newValue);
|
||||
long GetCurrentMarker();
|
||||
void SetCurrentMarker(long nNewValue);
|
||||
void playItem(LPDISPATCH pIWMPMedia);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_)
|
@ -1,52 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpdvd.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPDVD properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPDVD operations
|
||||
|
||||
BOOL CWMPDVD::GetIsAvailable(LPCTSTR bstrItem)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x3e9, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
|
||||
bstrItem);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPDVD::GetDomain()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x3ea, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPDVD::topMenu()
|
||||
{
|
||||
InvokeHelper(0x3eb, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPDVD::titleMenu()
|
||||
{
|
||||
InvokeHelper(0x3ec, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPDVD::back()
|
||||
{
|
||||
InvokeHelper(0x3ed, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPDVD::resume()
|
||||
{
|
||||
InvokeHelper(0x3ee, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
@ -1,38 +0,0 @@
|
||||
#if !defined(AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_)
|
||||
#define AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPDVD wrapper class
|
||||
|
||||
class CWMPDVD : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPDVD() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPDVD(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPDVD(const CWMPDVD& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
BOOL GetIsAvailable(LPCTSTR bstrItem);
|
||||
CString GetDomain();
|
||||
void topMenu();
|
||||
void titleMenu();
|
||||
void back();
|
||||
void resume();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_)
|
@ -1,45 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmperror.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmperroritem.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPError properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPError operations
|
||||
|
||||
void CWMPError::clearErrorQueue()
|
||||
{
|
||||
InvokeHelper(0x353, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
long CWMPError::GetErrorCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x354, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPErrorItem CWMPError::GetItem(long dwIndex)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x355, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
dwIndex);
|
||||
return CWMPErrorItem(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPError::webHelp()
|
||||
{
|
||||
InvokeHelper(0x356, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
@ -1,40 +0,0 @@
|
||||
#if !defined(AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_)
|
||||
#define AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPErrorItem;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPError wrapper class
|
||||
|
||||
class CWMPError : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPError() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPError(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPError(const CWMPError& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
void clearErrorQueue();
|
||||
long GetErrorCount();
|
||||
CWMPErrorItem GetItem(long dwIndex);
|
||||
void webHelp();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_)
|
@ -1,50 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmperroritem.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPErrorItem properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPErrorItem operations
|
||||
|
||||
long CWMPErrorItem::GetErrorCode()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x385, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPErrorItem::GetErrorDescription()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x386, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
VARIANT CWMPErrorItem::GetErrorContext()
|
||||
{
|
||||
VARIANT result;
|
||||
InvokeHelper(0x387, DISPATCH_PROPERTYGET, VT_VARIANT, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPErrorItem::GetRemedy()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x388, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPErrorItem::GetCustomUrl()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x389, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
@ -1,37 +0,0 @@
|
||||
#if !defined(AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_)
|
||||
#define AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPErrorItem wrapper class
|
||||
|
||||
class CWMPErrorItem : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPErrorItem() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPErrorItem(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPErrorItem(const CWMPErrorItem& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetErrorCode();
|
||||
CString GetErrorDescription();
|
||||
VARIANT GetErrorContext();
|
||||
long GetRemedy();
|
||||
CString GetCustomUrl();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_)
|
@ -1,167 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpmedia.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMedia properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMedia operations
|
||||
|
||||
BOOL CWMPMedia::GetIsIdentical(LPDISPATCH pIWMPMedia)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x2fb, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
|
||||
pIWMPMedia);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::GetSourceURL()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x2ef, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::GetName()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x2fc, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPMedia::SetName(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x2fc, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
long CWMPMedia::GetImageSourceWidth()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x2f0, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPMedia::GetImageSourceHeight()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x2f1, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPMedia::GetMarkerCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x2f2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
double CWMPMedia::getMarkerTime(long MarkerNum)
|
||||
{
|
||||
double result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x2f3, DISPATCH_METHOD, VT_R8, (void*)&result, parms,
|
||||
MarkerNum);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::getMarkerName(long MarkerNum)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x2f4, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
MarkerNum);
|
||||
return result;
|
||||
}
|
||||
|
||||
double CWMPMedia::GetDuration()
|
||||
{
|
||||
double result;
|
||||
InvokeHelper(0x2f5, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::GetDurationString()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x2f6, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPMedia::GetAttributeCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x2f7, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::getAttributeName(long lIndex)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x2f8, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
lIndex);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPMedia::getItemInfo(LPCTSTR bstrItemName)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x2f9, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
bstrItemName);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPMedia::setItemInfo(LPCTSTR bstrItemName, LPCTSTR bstrVal)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x2fa, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrItemName, bstrVal);
|
||||
}
|
||||
|
||||
CString CWMPMedia::getItemInfoByAtom(long lAtom)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x2fd, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
lAtom);
|
||||
return result;
|
||||
}
|
||||
|
||||
BOOL CWMPMedia::isMemberOf(LPDISPATCH pPlaylist)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x2fe, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
pPlaylist);
|
||||
return result;
|
||||
}
|
||||
|
||||
BOOL CWMPMedia::isReadOnlyItem(LPCTSTR bstrItemName)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x2ff, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
bstrItemName);
|
||||
return result;
|
||||
}
|
@ -1,50 +0,0 @@
|
||||
#if !defined(AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_)
|
||||
#define AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMedia wrapper class
|
||||
|
||||
class CWMPMedia : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPMedia() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPMedia(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPMedia(const CWMPMedia& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
BOOL GetIsIdentical(LPDISPATCH pIWMPMedia);
|
||||
CString GetSourceURL();
|
||||
CString GetName();
|
||||
void SetName(LPCTSTR lpszNewValue);
|
||||
long GetImageSourceWidth();
|
||||
long GetImageSourceHeight();
|
||||
long GetMarkerCount();
|
||||
double getMarkerTime(long MarkerNum);
|
||||
CString getMarkerName(long MarkerNum);
|
||||
double GetDuration();
|
||||
CString GetDurationString();
|
||||
long GetAttributeCount();
|
||||
CString getAttributeName(long lIndex);
|
||||
CString getItemInfo(LPCTSTR bstrItemName);
|
||||
void setItemInfo(LPCTSTR bstrItemName, LPCTSTR bstrVal);
|
||||
CString getItemInfoByAtom(long lAtom);
|
||||
BOOL isMemberOf(LPDISPATCH pPlaylist);
|
||||
BOOL isReadOnlyItem(LPCTSTR bstrItemName);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_)
|
@ -1,133 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpmediacollection.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpmedia.h"
|
||||
#include "wmpplaylist.h"
|
||||
#include "wmpstringcollection.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMediaCollection properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMediaCollection operations
|
||||
|
||||
CWMPMedia CWMPMediaCollection::add(LPCTSTR bstrURL)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c4, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrURL);
|
||||
return CWMPMedia(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getAll()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x1c5, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getByName(LPCTSTR bstrName)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c6, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrName);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getByGenre(LPCTSTR bstrGenre)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c7, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrGenre);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getByAuthor(LPCTSTR bstrAuthor)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c8, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrAuthor);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getByAlbum(LPCTSTR bstrAlbum)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c9, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrAlbum);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPMediaCollection::getByAttribute(LPCTSTR bstrAttribute, LPCTSTR bstrValue)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x1ca, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrAttribute, bstrValue);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPMediaCollection::remove(LPDISPATCH pItem, BOOL varfDeleteFile)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH VTS_BOOL;
|
||||
InvokeHelper(0x1cb, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pItem, varfDeleteFile);
|
||||
}
|
||||
|
||||
CWMPStringCollection CWMPMediaCollection::getAttributeStringCollection(LPCTSTR bstrAttribute, LPCTSTR bstrMediaType)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x1cd, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrAttribute, bstrMediaType);
|
||||
return CWMPStringCollection(pDispatch);
|
||||
}
|
||||
|
||||
long CWMPMediaCollection::getMediaAtom(LPCTSTR bstrItemName)
|
||||
{
|
||||
long result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1d6, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
|
||||
bstrItemName);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPMediaCollection::setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH VTS_BOOL;
|
||||
InvokeHelper(0x1d7, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pItem, varfIsDeleted);
|
||||
}
|
||||
|
||||
BOOL CWMPMediaCollection::isDeleted(LPDISPATCH pItem)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x1d8, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
pItem);
|
||||
return result;
|
||||
}
|
@ -1,50 +0,0 @@
|
||||
#if !defined(AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_)
|
||||
#define AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPMedia;
|
||||
class CWMPPlaylist;
|
||||
class CWMPStringCollection;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPMediaCollection wrapper class
|
||||
|
||||
class CWMPMediaCollection : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPMediaCollection() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPMediaCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPMediaCollection(const CWMPMediaCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
CWMPMedia add(LPCTSTR bstrURL);
|
||||
CWMPPlaylist getAll();
|
||||
CWMPPlaylist getByName(LPCTSTR bstrName);
|
||||
CWMPPlaylist getByGenre(LPCTSTR bstrGenre);
|
||||
CWMPPlaylist getByAuthor(LPCTSTR bstrAuthor);
|
||||
CWMPPlaylist getByAlbum(LPCTSTR bstrAlbum);
|
||||
CWMPPlaylist getByAttribute(LPCTSTR bstrAttribute, LPCTSTR bstrValue);
|
||||
void remove(LPDISPATCH pItem, BOOL varfDeleteFile);
|
||||
CWMPStringCollection getAttributeStringCollection(LPCTSTR bstrAttribute, LPCTSTR bstrMediaType);
|
||||
long getMediaAtom(LPCTSTR bstrItemName);
|
||||
void setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted);
|
||||
BOOL isDeleted(LPDISPATCH pItem);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_)
|
@ -1,233 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpnetwork.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPNetwork properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPNetwork operations
|
||||
|
||||
long CWMPNetwork::GetBandWidth()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x321, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetRecoveredPackets()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x322, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPNetwork::GetSourceProtocol()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x323, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetReceivedPackets()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x324, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetLostPackets()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x325, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetReceptionQuality()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x326, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetBufferingCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x327, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetBufferingProgress()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x328, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetBufferingTime()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x329, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::SetBufferingTime(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x329, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetFrameRate()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x32a, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetMaxBitRate()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x32b, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetBitRate()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x32c, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::getProxySettings(LPCTSTR bstrProtocol)
|
||||
{
|
||||
long result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x32d, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
|
||||
bstrProtocol);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::setProxySettings(LPCTSTR bstrProtocol, long lProxySetting)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_I4;
|
||||
InvokeHelper(0x32e, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrProtocol, lProxySetting);
|
||||
}
|
||||
|
||||
CString CWMPNetwork::getProxyName(LPCTSTR bstrProtocol)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x32f, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
bstrProtocol);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::setProxyName(LPCTSTR bstrProtocol, LPCTSTR bstrProxyName)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x330, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrProtocol, bstrProxyName);
|
||||
}
|
||||
|
||||
long CWMPNetwork::getProxyPort(LPCTSTR bstrProtocol)
|
||||
{
|
||||
long result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x331, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
|
||||
bstrProtocol);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::setProxyPort(LPCTSTR bstrProtocol, long lProxyPort)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_I4;
|
||||
InvokeHelper(0x332, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrProtocol, lProxyPort);
|
||||
}
|
||||
|
||||
CString CWMPNetwork::getProxyExceptionList(LPCTSTR bstrProtocol)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x333, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
bstrProtocol);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::setProxyExceptionList(LPCTSTR bstrProtocol, LPCTSTR pbstrExceptionList)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x334, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrProtocol, pbstrExceptionList);
|
||||
}
|
||||
|
||||
BOOL CWMPNetwork::getProxyBypassForLocal(LPCTSTR bstrProtocol)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x335, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
bstrProtocol);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::setProxyBypassForLocal(LPCTSTR bstrProtocol, BOOL fBypassForLocal)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BOOL;
|
||||
InvokeHelper(0x336, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrProtocol, fBypassForLocal);
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetMaxBandwidth()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x337, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPNetwork::SetMaxBandwidth(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x337, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetDownloadProgress()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x338, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetEncodedFrameRate()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x339, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPNetwork::GetFramesSkipped()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x33a, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
@ -1,60 +0,0 @@
|
||||
#if !defined(AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_)
|
||||
#define AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPNetwork wrapper class
|
||||
|
||||
class CWMPNetwork : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPNetwork() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPNetwork(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPNetwork(const CWMPNetwork& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetBandWidth();
|
||||
long GetRecoveredPackets();
|
||||
CString GetSourceProtocol();
|
||||
long GetReceivedPackets();
|
||||
long GetLostPackets();
|
||||
long GetReceptionQuality();
|
||||
long GetBufferingCount();
|
||||
long GetBufferingProgress();
|
||||
long GetBufferingTime();
|
||||
void SetBufferingTime(long nNewValue);
|
||||
long GetFrameRate();
|
||||
long GetMaxBitRate();
|
||||
long GetBitRate();
|
||||
long getProxySettings(LPCTSTR bstrProtocol);
|
||||
void setProxySettings(LPCTSTR bstrProtocol, long lProxySetting);
|
||||
CString getProxyName(LPCTSTR bstrProtocol);
|
||||
void setProxyName(LPCTSTR bstrProtocol, LPCTSTR bstrProxyName);
|
||||
long getProxyPort(LPCTSTR bstrProtocol);
|
||||
void setProxyPort(LPCTSTR bstrProtocol, long lProxyPort);
|
||||
CString getProxyExceptionList(LPCTSTR bstrProtocol);
|
||||
void setProxyExceptionList(LPCTSTR bstrProtocol, LPCTSTR pbstrExceptionList);
|
||||
BOOL getProxyBypassForLocal(LPCTSTR bstrProtocol);
|
||||
void setProxyBypassForLocal(LPCTSTR bstrProtocol, BOOL fBypassForLocal);
|
||||
long GetMaxBandwidth();
|
||||
void SetMaxBandwidth(long nNewValue);
|
||||
long GetDownloadProgress();
|
||||
long GetEncodedFrameRate();
|
||||
long GetFramesSkipped();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_)
|
@ -1,321 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpplayer4.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpcontrols.h"
|
||||
#include "WMPSettings.h"
|
||||
#include "wmpmedia.h"
|
||||
#include "wmpmediacollection.h"
|
||||
#include "wmpplaylistcollection.h"
|
||||
#include "wmpnetwork.h"
|
||||
#include "wmpplaylist.h"
|
||||
#include "wmpcdromcollection.h"
|
||||
#include "wmpclosedcaption.h"
|
||||
#include "WMPError.h"
|
||||
#include "wmpdvd.h"
|
||||
#include "WMPPlayerApplication.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayer4
|
||||
|
||||
IMPLEMENT_DYNCREATE(CWMPPlayer4, CWnd)
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayer4 properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayer4 operations
|
||||
|
||||
void CWMPPlayer4::close()
|
||||
{
|
||||
InvokeHelper(0x3, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
CString CWMPPlayer4::GetUrl()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x1, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetUrl(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
long CWMPPlayer4::GetOpenState()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
long CWMPPlayer4::GetPlayState()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0xa, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPControls CWMPPlayer4::GetControls()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x4, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPControls(pDispatch);
|
||||
}
|
||||
|
||||
CWMPSettings CWMPPlayer4::GetSettings()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x5, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPSettings(pDispatch);
|
||||
}
|
||||
|
||||
CWMPMedia CWMPPlayer4::GetCurrentMedia()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x6, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPMedia(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetCurrentMedia(LPDISPATCH newValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x6, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
newValue);
|
||||
}
|
||||
|
||||
CWMPMediaCollection CWMPPlayer4::GetMediaCollection()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x8, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPMediaCollection(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylistCollection CWMPPlayer4::GetPlaylistCollection()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x9, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlaylistCollection(pDispatch);
|
||||
}
|
||||
|
||||
CString CWMPPlayer4::GetVersionInfo()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0xb, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::launchURL(LPCTSTR bstrURL)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0xc, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrURL);
|
||||
}
|
||||
|
||||
CWMPNetwork CWMPPlayer4::GetNetwork()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x7, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPNetwork(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPPlayer4::GetCurrentPlaylist()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0xd, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetCurrentPlaylist(LPDISPATCH newValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0xd, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
newValue);
|
||||
}
|
||||
|
||||
CWMPCdromCollection CWMPPlayer4::GetCdromCollection()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0xe, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPCdromCollection(pDispatch);
|
||||
}
|
||||
|
||||
CWMPClosedCaption CWMPPlayer4::GetClosedCaption()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0xf, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPClosedCaption(pDispatch);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetIsOnline()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x10, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPError CWMPPlayer4::GetError()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x11, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPError(pDispatch);
|
||||
}
|
||||
|
||||
CString CWMPPlayer4::GetStatus()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x12, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPDVD CWMPPlayer4::GetDvd()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x28, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPDVD(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPPlayer4::newPlaylist(LPCTSTR bstrName, LPCTSTR bstrURL)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0x29, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrName, bstrURL);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPMedia CWMPPlayer4::newMedia(LPCTSTR bstrURL)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x2a, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrURL);
|
||||
return CWMPMedia(pDispatch);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetEnabled()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x13, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetEnabled(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x13, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetFullScreen()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x15, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetFullScreen(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x15, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetEnableContextMenu()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x16, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetEnableContextMenu(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x16, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetUiMode(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x17, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
CString CWMPPlayer4::GetUiMode()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x17, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetStretchToFit()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x18, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetStretchToFit(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x18, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetWindowlessVideo()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x19, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlayer4::SetWindowlessVideo(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x19, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayer4::GetIsRemote()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x1a, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPPlayerApplication CWMPPlayer4::GetPlayerApplication()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x1b, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlayerApplication(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPPlayer4::openPlayer(LPCTSTR bstrURL)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x1c, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrURL);
|
||||
}
|
@ -1,104 +0,0 @@
|
||||
#if !defined(AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_)
|
||||
#define AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPControls;
|
||||
class CWMPSettings;
|
||||
class CWMPMedia;
|
||||
class CWMPMediaCollection;
|
||||
class CWMPPlaylistCollection;
|
||||
class CWMPNetwork;
|
||||
class CWMPPlaylist;
|
||||
class CWMPCdromCollection;
|
||||
class CWMPClosedCaption;
|
||||
class CWMPError;
|
||||
class CWMPDVD;
|
||||
class CWMPPlayerApplication;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayer4 wrapper class
|
||||
|
||||
class CWMPPlayer4 : public CWnd
|
||||
{
|
||||
protected:
|
||||
DECLARE_DYNCREATE(CWMPPlayer4)
|
||||
public:
|
||||
CLSID const& GetClsid()
|
||||
{
|
||||
static CLSID const clsid
|
||||
= { 0x6bf52a52, 0x394a, 0x11d3, { 0xb1, 0x53, 0x0, 0xc0, 0x4f, 0x79, 0xfa, 0xa6 } };
|
||||
return clsid;
|
||||
}
|
||||
/*virtual BOOL Create(LPCTSTR lpszClassName,
|
||||
LPCTSTR lpszWindowName, DWORD dwStyle,
|
||||
const RECT& rect,
|
||||
CWnd* pParentWnd, UINT nID,
|
||||
CCreateContext* pContext = NULL)
|
||||
{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); }*/
|
||||
|
||||
BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle,
|
||||
const RECT& rect, CWnd* pParentWnd, UINT nID,
|
||||
CFile* pPersist = NULL, BOOL bStorage = FALSE,
|
||||
BSTR bstrLicKey = NULL)
|
||||
{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID,
|
||||
pPersist, bStorage, bstrLicKey); }
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
void close();
|
||||
CString GetUrl();
|
||||
void SetUrl(LPCTSTR lpszNewValue);
|
||||
long GetOpenState();
|
||||
long GetPlayState();
|
||||
CWMPControls GetControls();
|
||||
CWMPSettings GetSettings();
|
||||
CWMPMedia GetCurrentMedia();
|
||||
void SetCurrentMedia(LPDISPATCH newValue);
|
||||
CWMPMediaCollection GetMediaCollection();
|
||||
CWMPPlaylistCollection GetPlaylistCollection();
|
||||
CString GetVersionInfo();
|
||||
void launchURL(LPCTSTR bstrURL);
|
||||
CWMPNetwork GetNetwork();
|
||||
CWMPPlaylist GetCurrentPlaylist();
|
||||
void SetCurrentPlaylist(LPDISPATCH newValue);
|
||||
CWMPCdromCollection GetCdromCollection();
|
||||
CWMPClosedCaption GetClosedCaption();
|
||||
BOOL GetIsOnline();
|
||||
CWMPError GetError();
|
||||
CString GetStatus();
|
||||
CWMPDVD GetDvd();
|
||||
CWMPPlaylist newPlaylist(LPCTSTR bstrName, LPCTSTR bstrURL);
|
||||
CWMPMedia newMedia(LPCTSTR bstrURL);
|
||||
BOOL GetEnabled();
|
||||
void SetEnabled(BOOL bNewValue);
|
||||
BOOL GetFullScreen();
|
||||
void SetFullScreen(BOOL bNewValue);
|
||||
BOOL GetEnableContextMenu();
|
||||
void SetEnableContextMenu(BOOL bNewValue);
|
||||
void SetUiMode(LPCTSTR lpszNewValue);
|
||||
CString GetUiMode();
|
||||
BOOL GetStretchToFit();
|
||||
void SetStretchToFit(BOOL bNewValue);
|
||||
BOOL GetWindowlessVideo();
|
||||
void SetWindowlessVideo(BOOL bNewValue);
|
||||
BOOL GetIsRemote();
|
||||
CWMPPlayerApplication GetPlayerApplication();
|
||||
void openPlayer(LPCTSTR bstrURL);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_)
|
@ -1,39 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpplayerapplication.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayerApplication properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayerApplication operations
|
||||
|
||||
void CWMPPlayerApplication::switchToPlayerApplication()
|
||||
{
|
||||
InvokeHelper(0x44d, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPPlayerApplication::switchToControl()
|
||||
{
|
||||
InvokeHelper(0x44e, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
BOOL CWMPPlayerApplication::GetPlayerDocked()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x44f, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
BOOL CWMPPlayerApplication::GetHasDisplay()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x450, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
#if !defined(AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_)
|
||||
#define AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlayerApplication wrapper class
|
||||
|
||||
class CWMPPlayerApplication : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPPlayerApplication() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPPlayerApplication(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPPlayerApplication(const CWMPPlayerApplication& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
void switchToPlayerApplication();
|
||||
void switchToControl();
|
||||
BOOL GetPlayerDocked();
|
||||
BOOL GetHasDisplay();
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_)
|
@ -1,132 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpplaylist.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "WMPMedia.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylist properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylist operations
|
||||
|
||||
long CWMPPlaylist::GetCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0xc9, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPPlaylist::GetName()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0xca, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlaylist::SetName(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0xca, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
long CWMPPlaylist::GetAttributeCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0xd2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPPlaylist::GetAttributeName(long lIndex)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0xd3, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, parms,
|
||||
lIndex);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPMedia CWMPPlaylist::GetItem(long lIndex)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0xd4, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
lIndex);
|
||||
return CWMPMedia(pDispatch);
|
||||
}
|
||||
|
||||
CString CWMPPlaylist::getItemInfo(LPCTSTR bstrName)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0xcb, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
bstrName);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlaylist::setItemInfo(LPCTSTR bstrName, LPCTSTR bstrValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BSTR;
|
||||
InvokeHelper(0xcc, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrName, bstrValue);
|
||||
}
|
||||
|
||||
BOOL CWMPPlaylist::GetIsIdentical(LPDISPATCH pIWMPPlaylist)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0xd5, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
|
||||
pIWMPPlaylist);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPPlaylist::clear()
|
||||
{
|
||||
InvokeHelper(0xcd, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
|
||||
}
|
||||
|
||||
void CWMPPlaylist::insertItem(long lIndex, LPDISPATCH pIWMPMedia)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4 VTS_DISPATCH;
|
||||
InvokeHelper(0xce, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
lIndex, pIWMPMedia);
|
||||
}
|
||||
|
||||
void CWMPPlaylist::appendItem(LPDISPATCH pIWMPMedia)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0xcf, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pIWMPMedia);
|
||||
}
|
||||
|
||||
void CWMPPlaylist::removeItem(LPDISPATCH pIWMPMedia)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0xd0, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pIWMPMedia);
|
||||
}
|
||||
|
||||
void CWMPPlaylist::moveItem(long lIndexOld, long lIndexNew)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4 VTS_I4;
|
||||
InvokeHelper(0xd1, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
lIndexOld, lIndexNew);
|
||||
}
|
@ -1,50 +0,0 @@
|
||||
#if !defined(AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_)
|
||||
#define AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPMedia;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylist wrapper class
|
||||
|
||||
class CWMPPlaylist : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPPlaylist() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPPlaylist(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPPlaylist(const CWMPPlaylist& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetCount();
|
||||
CString GetName();
|
||||
void SetName(LPCTSTR lpszNewValue);
|
||||
long GetAttributeCount();
|
||||
CString GetAttributeName(long lIndex);
|
||||
CWMPMedia GetItem(long lIndex);
|
||||
CString getItemInfo(LPCTSTR bstrName);
|
||||
void setItemInfo(LPCTSTR bstrName, LPCTSTR bstrValue);
|
||||
BOOL GetIsIdentical(LPDISPATCH pIWMPPlaylist);
|
||||
void clear();
|
||||
void insertItem(long lIndex, LPDISPATCH pIWMPMedia);
|
||||
void appendItem(LPDISPATCH pIWMPMedia);
|
||||
void removeItem(LPDISPATCH pIWMPMedia);
|
||||
void moveItem(long lIndexOld, long lIndexNew);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_)
|
@ -1,35 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpplaylistarray.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpplaylist.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistArray properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistArray operations
|
||||
|
||||
long CWMPPlaylistArray::GetCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x1f5, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPPlaylistArray::Item(long lIndex)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x1f6, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
lIndex);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
@ -1,38 +0,0 @@
|
||||
#if !defined(AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_)
|
||||
#define AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPPlaylist;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistArray wrapper class
|
||||
|
||||
class CWMPPlaylistArray : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPPlaylistArray() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPPlaylistArray(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPPlaylistArray(const CWMPPlaylistArray& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetCount();
|
||||
CWMPPlaylist Item(long lIndex);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_)
|
@ -1,82 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpplaylistcollection.h"
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
#include "wmpplaylist.h"
|
||||
#include "WMPPlaylistArray.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistCollection properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistCollection operations
|
||||
|
||||
CWMPPlaylist CWMPPlaylistCollection::newPlaylist(LPCTSTR bstrName)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x228, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrName);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylistArray CWMPPlaylistCollection::getAll()
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
InvokeHelper(0x229, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, NULL);
|
||||
return CWMPPlaylistArray(pDispatch);
|
||||
}
|
||||
|
||||
CWMPPlaylistArray CWMPPlaylistCollection::getByName(LPCTSTR bstrName)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x22a, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
bstrName);
|
||||
return CWMPPlaylistArray(pDispatch);
|
||||
}
|
||||
|
||||
void CWMPPlaylistCollection::remove(LPDISPATCH pItem)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x22c, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pItem);
|
||||
}
|
||||
|
||||
void CWMPPlaylistCollection::setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH VTS_BOOL;
|
||||
InvokeHelper(0x230, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
pItem, varfIsDeleted);
|
||||
}
|
||||
|
||||
BOOL CWMPPlaylistCollection::isDeleted(LPDISPATCH pItem)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x231, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
pItem);
|
||||
return result;
|
||||
}
|
||||
|
||||
CWMPPlaylist CWMPPlaylistCollection::importPlaylist(LPDISPATCH pItem)
|
||||
{
|
||||
LPDISPATCH pDispatch;
|
||||
static BYTE parms[] =
|
||||
VTS_DISPATCH;
|
||||
InvokeHelper(0x232, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
|
||||
pItem);
|
||||
return CWMPPlaylist(pDispatch);
|
||||
}
|
@ -1,44 +0,0 @@
|
||||
#if !defined(AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_)
|
||||
#define AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
// Dispatch interfaces referenced by this interface
|
||||
class CWMPPlaylist;
|
||||
class CWMPPlaylistArray;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPPlaylistCollection wrapper class
|
||||
|
||||
class CWMPPlaylistCollection : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPPlaylistCollection() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPPlaylistCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPPlaylistCollection(const CWMPPlaylistCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
CWMPPlaylist newPlaylist(LPCTSTR bstrName);
|
||||
CWMPPlaylistArray getAll();
|
||||
CWMPPlaylistArray getByName(LPCTSTR bstrName);
|
||||
void remove(LPDISPATCH pItem);
|
||||
void setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted);
|
||||
BOOL isDeleted(LPDISPATCH pItem);
|
||||
CWMPPlaylist importPlaylist(LPDISPATCH pItem);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_)
|
@ -1,193 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpsettings.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPSettings properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPSettings operations
|
||||
|
||||
BOOL CWMPSettings::GetIsAvailable(LPCTSTR bstrItem)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x71, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
|
||||
bstrItem);
|
||||
return result;
|
||||
}
|
||||
|
||||
BOOL CWMPSettings::GetAutoStart()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x65, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetAutoStart(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x65, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
CString CWMPSettings::GetBaseURL()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x6c, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetBaseURL(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x6c, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
CString CWMPSettings::GetDefaultFrame()
|
||||
{
|
||||
CString result;
|
||||
InvokeHelper(0x6d, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetDefaultFrame(LPCTSTR lpszNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x6d, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
lpszNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPSettings::GetInvokeURLs()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x67, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetInvokeURLs(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x67, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPSettings::GetMute()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x68, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetMute(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x68, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
||||
|
||||
long CWMPSettings::GetPlayCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x69, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetPlayCount(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x69, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
double CWMPSettings::GetRate()
|
||||
{
|
||||
double result;
|
||||
InvokeHelper(0x6a, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetRate(double newValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_R8;
|
||||
InvokeHelper(0x6a, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
newValue);
|
||||
}
|
||||
|
||||
long CWMPSettings::GetBalance()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x66, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetBalance(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x66, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
long CWMPSettings::GetVolume()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x6b, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetVolume(long nNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x6b, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
nNewValue);
|
||||
}
|
||||
|
||||
BOOL CWMPSettings::getMode(LPCTSTR bstrMode)
|
||||
{
|
||||
BOOL result;
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR;
|
||||
InvokeHelper(0x6e, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
|
||||
bstrMode);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::setMode(LPCTSTR bstrMode, BOOL varfMode)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BSTR VTS_BOOL;
|
||||
InvokeHelper(0x6f, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
|
||||
bstrMode, varfMode);
|
||||
}
|
||||
|
||||
BOOL CWMPSettings::GetEnableErrorDialogs()
|
||||
{
|
||||
BOOL result;
|
||||
InvokeHelper(0x70, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
void CWMPSettings::SetEnableErrorDialogs(BOOL bNewValue)
|
||||
{
|
||||
static BYTE parms[] =
|
||||
VTS_BOOL;
|
||||
InvokeHelper(0x70, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
|
||||
bNewValue);
|
||||
}
|
@ -1,55 +0,0 @@
|
||||
#if !defined(AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_)
|
||||
#define AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPSettings wrapper class
|
||||
|
||||
class CWMPSettings : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPSettings() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPSettings(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPSettings(const CWMPSettings& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
BOOL GetIsAvailable(LPCTSTR bstrItem);
|
||||
BOOL GetAutoStart();
|
||||
void SetAutoStart(BOOL bNewValue);
|
||||
CString GetBaseURL();
|
||||
void SetBaseURL(LPCTSTR lpszNewValue);
|
||||
CString GetDefaultFrame();
|
||||
void SetDefaultFrame(LPCTSTR lpszNewValue);
|
||||
BOOL GetInvokeURLs();
|
||||
void SetInvokeURLs(BOOL bNewValue);
|
||||
BOOL GetMute();
|
||||
void SetMute(BOOL bNewValue);
|
||||
long GetPlayCount();
|
||||
void SetPlayCount(long nNewValue);
|
||||
double GetRate();
|
||||
void SetRate(double newValue);
|
||||
long GetBalance();
|
||||
void SetBalance(long nNewValue);
|
||||
long GetVolume();
|
||||
void SetVolume(long nNewValue);
|
||||
BOOL getMode(LPCTSTR bstrMode);
|
||||
void setMode(LPCTSTR bstrMode, BOOL varfMode);
|
||||
BOOL GetEnableErrorDialogs();
|
||||
void SetEnableErrorDialogs(BOOL bNewValue);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_)
|
@ -1,32 +0,0 @@
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "wmpstringcollection.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPStringCollection properties
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPStringCollection operations
|
||||
|
||||
long CWMPStringCollection::GetCount()
|
||||
{
|
||||
long result;
|
||||
InvokeHelper(0x191, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
|
||||
return result;
|
||||
}
|
||||
|
||||
CString CWMPStringCollection::Item(long lIndex)
|
||||
{
|
||||
CString result;
|
||||
static BYTE parms[] =
|
||||
VTS_I4;
|
||||
InvokeHelper(0x192, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
|
||||
lIndex);
|
||||
return result;
|
||||
}
|
@ -1,34 +0,0 @@
|
||||
#if !defined(AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_)
|
||||
#define AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
|
||||
|
||||
// NOTE: Do not modify the contents of this file. If this class is regenerated by
|
||||
// Microsoft Visual C++, your modifications will be overwritten.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CWMPStringCollection wrapper class
|
||||
|
||||
class CWMPStringCollection : public COleDispatchDriver
|
||||
{
|
||||
public:
|
||||
CWMPStringCollection() {} // Calls COleDispatchDriver default constructor
|
||||
CWMPStringCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
|
||||
CWMPStringCollection(const CWMPStringCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
|
||||
|
||||
// Attributes
|
||||
public:
|
||||
|
||||
// Operations
|
||||
public:
|
||||
long GetCount();
|
||||
CString Item(long lIndex);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_)
|
@ -1,4 +1,4 @@
|
||||
libdir = $(hexchatdir)/plugins
|
||||
libdir = $(hexchatdir)
|
||||
|
||||
lib_LTLIBRARIES = xdcc.la
|
||||
xdcc_la_SOURCES = xdcc.c
|
||||
|
@ -12,7 +12,6 @@ src/common/text.c
|
||||
src/common/util.c
|
||||
src/common/dbus/dbus-client.c
|
||||
src/common/dbus/dbus-plugin.c
|
||||
src/fe-gtk/about.c
|
||||
src/fe-gtk/ascii.c
|
||||
src/fe-gtk/banlist.c
|
||||
src/fe-gtk/chanlist.c
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user