<br><br><div class="gmail_quote">2011/11/17 Jean-Baptiste Kempf <span dir="ltr"><<a href="mailto:jb@videolan.org">jb@videolan.org</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
On Thu, Nov 17, 2011 at 09:32:37PM +0700, Sergey Radionov wrote :<br>
> +#ifdef _MSC_VER<br>
> +<br>
> +const CATID CATID_SafeForScripting =<br>
> + {0x7dd95801, 0x9882, 0x11cf, {0x9f,0xa9,0x00,0xaa,0x00,0x6c,0x42,0xc4}};<br>
> +const CATID CATID_SafeForInitializing =<br>
> + {0x7dd95802,0x9882,0x11cf,{0x9f,0xa9,0x00,0xaa,0x00,0x6c,0x42,0xc4}};<br>
> +<br>
> +#else /*!_MSC_VER*/<br>
> +<br>
> #include <_mingw.h><br>
><br>
> #ifdef __MINGW64_VERSION_MAJOR<br>
> @@ -60,7 +69,7 @@ static DEFINE_GUID(CATID_SafeForScripting, \<br>
> 0x7DD95801, 0x9882, 0x11CF, 0x9F, 0xA9, 0x00,0xAA,0x00,0x6C,0x42,0xC4);<br>
><br>
> #endif /* __MINGW64_VERSION_MAJOR */<br>
> -<br>
> +#endif /*_MSC_VER*/<br>
<br>
I don't see why you can't use the same codepath here.<br></blockquote><div>I don't understand what you mean.<br><br> <br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
> +#ifdef _MSC_VER<br>
> +#define PROGID_STR "VideoLAN.VLCPlugin"<br>
> +#else<br>
> #define PROGID_STR COMPANY_STR"."PROGRAM_STR<br>
> +#endif<br>
No. COMPANY_STR is "VideoLAN". You shouldn't need that.<br>
Else, redefine COMPANY_STR as "VideoLAN".<br></blockquote><div><br>Problem is that <br><br>#define PROGID_STR COMPANY_STR"."PROGRAM_STR<br>and some later <br>TEXT(PROGID_STR)<br>
<br>expands to <br><br> L"VideoLAN"".""VLCPlugin"<br><br>and Visual C not understand this. <br>It want <br>L"VideoLAN"L"."L"VLCPlugin"<br>or <br>L"VideoLAN.VLCPlugin"<br>
<br>so we need replace TEXT(PROGID_STR) to PROGID_STR (without TEXT) everywhere, and <br>
#define COMPANY_STR "VideoLAN" to #define COMPANY_STR TEXT("VideoLAN") and<br>
#define PROGRAM_STR "VLCPlugin" to #define PROGRAM_STR TEXT("VLCPlugin") and<br>
#define PROGID_STR COMPANY_STR"."PROGRAM_STR to #define PROGID_STR COMPANY_STR TEXT(".") PROGRAM_STR<br>
and maybe some more, I don't remember now...<br><br>so, I think,<br>
> +#ifdef _MSC_VER<br>
> +#define PROGID_STR "VideoLAN.VLCPlugin"<br>
> +#else<br>
> #define PROGID_STR COMPANY_STR"."PROGRAM_STR<br>
> +#endif<br>
is simplest way to satisfy VC<br><br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
> +#ifdef _MSC_VER<br>
> + _snprintf(timeBuffer, sizeof(timeBuffer), ":start-time=%d", _i_time);<br>
> +#else<br>
> snprintf(timeBuffer, sizeof(timeBuffer), ":start-time=%d", _i_time);<br>
> +#endif<br>
<br>
#ifdef _MSC_VER<br>
# define snprintf _snprintf<br>
#endif<br>
<br>
WOuld be better and more global.<br>
<br>
> +#ifdef _MSC_VER<br>
> + if( !_stricmp( n, h->n ) )<br>
> +#else<br>
> if( !strcasecmp( n, h->n ) )<br>
> +#endif<br>
<br>
idem for _stricmp and strcasecmp<br></blockquote><div>accepted.<br> <br></div><div></div><div></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Best Regards,<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Jean-Baptiste Kempf<br>
<a href="http://www.jbkempf.com/" target="_blank">http://www.jbkempf.com/</a> - +33 672 704 734<br>
Sent from my Electronic Device<br>
</font></span><br>_______________________________________________<br>
vlc-devel mailing list<br>
To unsubscribe or modify your subscription options:<br>
<a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
<br></blockquote></div><br>