Changeset 242
- Timestamp:
- Jan 11, 2014, 2:53:56 PM (10 years ago)
- Location:
- trunk/DirectShowSpy
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DirectShowSpy/DirectShowSpy.idl
r231 r242 17 17 interface ISpy : IDispatch 18 18 { 19 [id(1), propget] HRESULT MonikerDisplayName([out, retval] BSTR* psMonikerDisplayName); 20 [id(2), propget] HRESULT CreationTime([out, retval] DATE* pfTime); 21 [id(3), propget] HRESULT FriendlyName([out, retval] BSTR* psFriendlyName); 22 [id(3), propput] HRESULT FriendlyName([in] BSTR sFriendlyName); 19 23 }; 20 24 [ -
trunk/DirectShowSpy/DirectShowSpy.rc
r240 r242 59 59 60 60 VS_VERSION_INFO VERSIONINFO 61 FILEVERSION 1, 0, 0, 1 12761 FILEVERSION 1, 0, 0, 1210 62 62 PRODUCTVERSION 1,0,0,1 63 63 FILEFLAGSMASK 0x3fL … … 78 78 VALUE "CompanyName", "Roman Ryltsov" 79 79 VALUE "FileDescription", "Alax.Info DirectShow Spy Module" 80 VALUE "FileVersion", "1, 0, 0, 1 127\0"80 VALUE "FileVersion", "1, 0, 0, 1210\0" 81 81 VALUE "InternalName", "DirectShowSpy.dll" 82 82 VALUE "LegalCopyright", "Copyright © Alax.Info, Roman Ryltsov, 2008-2014" … … 152 152 FONT 8, "MS Shell Dlg", 400, 0, 0x0 153 153 BEGIN 154 LTEXT "Use controls below to review <A HREF=""http://msdn.microsoft.com/en-us/library/dd390342%28VS.85%29.aspx"">Intelligent Connect</A> activity on recently created filter graphs.",IDC_GRAPHBUILDERCALLBACK_GRAPH_INTRODUCTION,6,6,215,18 154 LTEXT "Use controls below to review <A HREF=""http://msdn.microsoft.com/en-us/library/dd390342%28VS.85%29.aspx"">Intelligent Connect</A> activity on recently created filter graphs.",IDC_GRAPHBUILDERCALLBACK_GRAPH_INTRODUCTION,6,6,215,18,0,WS_EX_TRANSPARENT 155 155 CONTROL "",IDC_GRAPHBUILDERCALLBACK_GRAPH_GRAPH,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_EDITLABELS | LVS_ALIGNLEFT | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,6,30,215,54 156 156 CONTROL "",IDC_GRAPHBUILDERCALLBACK_GRAPH_LOG,"SysListView32",LVS_REPORT | LVS_SHOWSELALWAYS | LVS_ALIGNLEFT | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,6,90,215,90 … … 250 250 BEGIN 251 251 CONTROL "",IDC_FILTERGRAPHHELPER_PROPERTYFRAME_TREE, 252 "SysTreeView32",TVS_HASLINES | TVS_ SHOWSELALWAYS| WS_BORDER | WS_HSCROLL | WS_TABSTOP,6,6,156,222252 "SysTreeView32",TVS_HASLINES | TVS_LINESATROOT | TVS_SHOWSELALWAYS | TVS_INFOTIP | WS_BORDER | WS_HSCROLL | WS_TABSTOP,6,6,156,222 253 253 EDITTEXT IDC_FILTERGRAPHHELPER_PROPERTYFRAME_TEXT,168,6,246,222,ES_MULTILINE | ES_AUTOVSCROLL | ES_AUTOHSCROLL | ES_READONLY | WS_VSCROLL | WS_HSCROLL 254 254 DEFPUSHBUTTON "OK",IDOK,246,234,50,14 … … 279 279 END 280 280 281 IDD_FILTERGRAPHHELPER_ACTION DIALOGEX 0, 0, 374, 206 282 STYLE DS_SETFONT | DS_FIXEDSYS | DS_CONTROL | WS_CHILD 283 EXSTYLE WS_EX_CONTROLPARENT 284 FONT 8, "MS Shell Dlg", 400, 0, 0x0 285 BEGIN 286 PUSHBUTTON "Save Filter Graph As...",IDC_FILTERGRAPHHELPER_ACTION_SAVEAS,6,30,120,14 287 LTEXT "Save DirectShow Filter Graph into .GRF file for further open in GraphEdit or <A HREF=""http://code.google.com/p/graph-studio-next/"">GraphStudioNext</A> software.",IDC_FILTERGRAPHHELPER_ACTION_SAVEASDESCRIPTION,138,30,204,24,0,WS_EX_TRANSPARENT 288 PUSHBUTTON "Open in GraphStudioNext (F7)",IDC_FILTERGRAPHHELPER_ACTION_OPENGSN,6,66,120,14 289 LTEXT "The DirectShow Filter Graph is known to be published on <A HREF=""http://msdn.microsoft.com/en-us/library/windows/desktop/ms694349"">Running Object Table</A>, and can be opened by GraphStudioNext for further interactive review.",IDC_FILTERGRAPHHELPER_ACTION_OPENGSNDESCRIPTION,138,66,204,24,0,WS_EX_TRANSPARENT 290 PUSHBUTTON "Open in GraphEdit (F8)",IDC_FILTERGRAPHHELPER_ACTION_OPENGE,6,102,120,14 291 LTEXT "Similarly to the above, open in Widnows SDK <A HREF=""http://msdn.microsoft.com/en-us/library/windows/desktop/dd407274"">GraphEdit</A> application.",IDC_FILTERGRAPHHELPER_ACTION_OPENGEDESCRIPTION,138,102,204,24,0,WS_EX_TRANSPARENT 292 LTEXT "DirectShow Filter Graph Actions",IDC_FILTERGRAPHHELPER_ACTION_TITLE,6,0,294,18 293 PUSHBUTTON "Open Filter Graph List (F2)",IDC_FILTERGRAPHHELPER_ACTION_OPENLIST,6,138,120,14 294 LTEXT "Open list of DirectShow Filter Graphs listed on Running Object Table.",IDC_FILTERGRAPHHELPER_ACTION_OPENLISTDESCRIPTION,138,138,204,24,0,WS_EX_TRANSPARENT 295 END 296 281 297 282 298 ///////////////////////////////////////////////////////////////////////////// … … 288 304 GUIDELINES DESIGNINFO 289 305 BEGIN 306 IDD_GRAPHBUILDERCALLBACK_GRAPH_PROPERTYPAGE, DIALOG 307 BEGIN 308 END 309 310 IDD_FILTERGRAPHLIST_LIST_PROPERTYPAGE, DIALOG 311 BEGIN 312 END 313 314 IDD_FILTERGRAPHHELPER_PROPERTYFRAME, DIALOG 315 BEGIN 316 END 317 290 318 IDD_FILTERGRAPHHELPER_EMAIL, DIALOG 291 319 BEGIN 292 RIGHTMARGIN, 3 08320 RIGHTMARGIN, 366 293 321 BOTTOMMARGIN, 248 294 322 END 323 324 IDD_FILTERGRAPHHELPER_ACTION, DIALOG 325 BEGIN 326 RIGHTMARGIN, 368 327 BOTTOMMARGIN, 200 328 END 295 329 END 296 330 #endif // APSTUDIO_INVOKED … … 303 337 304 338 IDR_EMAILTOOLS TYPELIB "..\\..\\Repository-Private\\Utilities\\EmailTools\\_Bin\\Win32\\Release\\EmailTools\\EmailTools.tlb" 339 340 ///////////////////////////////////////////////////////////////////////////// 341 // 342 // Accelerator 343 // 344 345 IDD_FILTERGRAPHHELPER_PROPERTYFRAME ACCELERATORS 346 BEGIN 347 VK_F2, IDC_FILTERGRAPHHELPER_ACTION_OPENLIST, VIRTKEY, NOINVERT 348 VK_F7, IDC_FILTERGRAPHHELPER_ACTION_OPENGSN, VIRTKEY, NOINVERT 349 VK_F8, IDC_FILTERGRAPHHELPER_ACTION_OPENGE, VIRTKEY, NOINVERT 350 END 351 352 IDD_FILTERGRAPHLIST_LIST_PROPERTYPAGE ACCELERATORS 353 BEGIN 354 VK_F6, IDC_FILTERGRAPHLIST_LIST_CHECKALL, VIRTKEY, NOINVERT 355 VK_F7, IDC_FILTERGRAPHLIST_LIST_OPENGSN, VIRTKEY, NOINVERT 356 VK_F8, IDC_FILTERGRAPHLIST_LIST_OPENGE, VIRTKEY, NOINVERT 357 VK_F5, IDC_FILTERGRAPHLIST_LIST_REFRESH, VIRTKEY, NOINVERT 358 END 359 360 361 ///////////////////////////////////////////////////////////////////////////// 362 // 363 // Menu 364 // 365 366 IDD_FILTERGRAPHLIST_LIST_PROPERTYPAGE MENU 367 BEGIN 368 POPUP "(item)" 369 BEGIN 370 MENUITEM "&Check", IDC_FILTERGRAPHLIST_LIST_CHECK 371 MENUITEM "Check All\tF6", IDC_FILTERGRAPHLIST_LIST_CHECKALL 372 MENUITEM "C&opy", IDC_FILTERGRAPHLIST_LIST_COPYTOCLIPBOARD 373 MENUITEM SEPARATOR 374 MENUITEM "Open with &GraphStudioNext\tF7", IDC_FILTERGRAPHLIST_LIST_OPENGSN 375 MENUITEM "Open with Graph&Edit\tF8", IDC_FILTERGRAPHLIST_LIST_OPENGE 376 MENUITEM SEPARATOR 377 MENUITEM "&Refresh\tF5", IDC_FILTERGRAPHLIST_LIST_REFRESH 378 MENUITEM SEPARATOR 379 MENUITEM "&Properties...", IDC_FILTERGRAPHLIST_LIST_PROPERTIES 380 END 381 END 382 305 383 306 384 ///////////////////////////////////////////////////////////////////////////// … … 380 458 IDD_FILTERGRAPHLIST_LIST_PROPERTYPAGE "Filter Graphs" 381 459 IDC_FILTERGRAPHLIST_LIST_GRAPH 382 "v, 1\nx, 0x420, 0x420\nc, ""Process, Instance"", 150, -1\nc, Process Name, 120, 1\nc, Creation Time, 90, 2\nc, F ilters, 60, 3\nc, State, 60, 4\nc, Process Image Directory, 420, 5\n"460 "v, 1\nx, 0x420, 0x420\nc, ""Process, Instance"", 150, -1\nc, Process Name, 120, 1\nc, Creation Time, 90, 2\nc, Friendly Name, 120, 3\nc, Filters, 60, 4\nc, State, 60, 5\nc, Process Image Directory, 420, 6\n" 383 461 END 384 462 -
trunk/DirectShowSpy/DirectShowSpy_i.c
r233 r242 7 7 8 8 /* File created by MIDL compiler version 7.00.0555 */ 9 /* at Fri Jan 10 11:37:2020149 /* at Sat Jan 11 18:11:25 2014 10 10 */ 11 11 /* Compiler settings for DirectShowSpy.idl: -
trunk/DirectShowSpy/DirectShowSpy_i.h
r233 r242 5 5 6 6 /* File created by MIDL compiler version 7.00.0555 */ 7 /* at Fri Jan 10 11:37:2020147 /* at Sat Jan 11 18:11:25 2014 8 8 */ 9 9 /* Compiler settings for DirectShowSpy.idl: … … 172 172 { 173 173 public: 174 virtual /* [propget][id] */ HRESULT STDMETHODCALLTYPE get_MonikerDisplayName( 175 /* [retval][out] */ BSTR *psMonikerDisplayName) = 0; 176 177 virtual /* [propget][id] */ HRESULT STDMETHODCALLTYPE get_CreationTime( 178 /* [retval][out] */ DATE *pfTime) = 0; 179 180 virtual /* [propget][id] */ HRESULT STDMETHODCALLTYPE get_FriendlyName( 181 /* [retval][out] */ BSTR *psFriendlyName) = 0; 182 183 virtual /* [propput][id] */ HRESULT STDMETHODCALLTYPE put_FriendlyName( 184 /* [in] */ BSTR sFriendlyName) = 0; 185 174 186 }; 175 187 … … 221 233 /* [out] */ UINT *puArgErr); 222 234 235 /* [propget][id] */ HRESULT ( STDMETHODCALLTYPE *get_MonikerDisplayName )( 236 ISpy * This, 237 /* [retval][out] */ BSTR *psMonikerDisplayName); 238 239 /* [propget][id] */ HRESULT ( STDMETHODCALLTYPE *get_CreationTime )( 240 ISpy * This, 241 /* [retval][out] */ DATE *pfTime); 242 243 /* [propget][id] */ HRESULT ( STDMETHODCALLTYPE *get_FriendlyName )( 244 ISpy * This, 245 /* [retval][out] */ BSTR *psFriendlyName); 246 247 /* [propput][id] */ HRESULT ( STDMETHODCALLTYPE *put_FriendlyName )( 248 ISpy * This, 249 /* [in] */ BSTR sFriendlyName); 250 223 251 END_INTERFACE 224 252 } ISpyVtbl; … … 256 284 ( (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) ) 257 285 286 287 #define ISpy_get_MonikerDisplayName(This,psMonikerDisplayName) \ 288 ( (This)->lpVtbl -> get_MonikerDisplayName(This,psMonikerDisplayName) ) 289 290 #define ISpy_get_CreationTime(This,pfTime) \ 291 ( (This)->lpVtbl -> get_CreationTime(This,pfTime) ) 292 293 #define ISpy_get_FriendlyName(This,psFriendlyName) \ 294 ( (This)->lpVtbl -> get_FriendlyName(This,psFriendlyName) ) 295 296 #define ISpy_put_FriendlyName(This,sFriendlyName) \ 297 ( (This)->lpVtbl -> put_FriendlyName(This,sFriendlyName) ) 258 298 259 299 #endif /* COBJMACROS */ -
trunk/DirectShowSpy/DirectShowSpy_p.c
r233 r242 5 5 6 6 /* File created by MIDL compiler version 7.00.0555 */ 7 /* at Fri Jan 10 11:37:2020147 /* at Sat Jan 11 18:11:25 2014 8 8 */ 9 9 /* Compiler settings for DirectShowSpy.idl: … … 50 50 #include "DirectShowSpy_i.h" 51 51 52 #define TYPE_FORMAT_STRING_SIZE 6553 #define PROC_FORMAT_STRING_SIZE 14552 #define TYPE_FORMAT_STRING_SIZE 83 53 #define PROC_FORMAT_STRING_SIZE 253 54 54 #define EXPR_FORMAT_STRING_SIZE 1 55 55 #define TRANSMIT_AS_TABLE_SIZE 0 … … 131 131 { 132 132 133 /* Procedure get_ FilterGraph*/133 /* Procedure get_MonikerDisplayName */ 134 134 135 135 0x33, /* FC_AUTO_HANDLE */ … … 143 143 0x2, /* 2 */ 144 144 /* 16 */ 0x8, /* 8 */ 145 0x 1, /* Ext Flags: new corr desc, */146 /* 18 */ NdrFcShort( 0x 0 ), /* 0*/145 0x3, /* Ext Flags: new corr desc, clt corr check, */ 146 /* 18 */ NdrFcShort( 0x1 ), /* 1 */ 147 147 /* 20 */ NdrFcShort( 0x0 ), /* 0 */ 148 148 /* 22 */ NdrFcShort( 0x0 ), /* 0 */ 149 149 150 /* Parameter p pFilterGraphUnknown*/151 152 /* 24 */ NdrFcShort( 0x 13 ), /* Flags: must size, must free, out,*/150 /* Parameter psMonikerDisplayName */ 151 152 /* 24 */ NdrFcShort( 0x2113 ), /* Flags: must size, must free, out, simple ref, srv alloc size=8 */ 153 153 /* 26 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 154 /* 28 */ NdrFcShort( 0x2 ), /* Type Offset=2 */154 /* 28 */ NdrFcShort( 0x20 ), /* Type Offset=32 */ 155 155 156 156 /* Return value */ … … 161 161 0x0, /* 0 */ 162 162 163 /* Procedure put_FilterGraph*/163 /* Procedure get_CreationTime */ 164 164 165 165 /* 36 */ 0x33, /* FC_AUTO_HANDLE */ … … 169 169 /* 44 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 170 170 /* 46 */ NdrFcShort( 0x0 ), /* 0 */ 171 /* 48 */ NdrFcShort( 0x 8 ), /* 8*/172 /* 50 */ 0x4 6, /* Oi2 Flags: clt must size,has return, has ext, */171 /* 48 */ NdrFcShort( 0x2c ), /* 44 */ 172 /* 50 */ 0x44, /* Oi2 Flags: has return, has ext, */ 173 173 0x2, /* 2 */ 174 174 /* 52 */ 0x8, /* 8 */ … … 178 178 /* 58 */ NdrFcShort( 0x0 ), /* 0 */ 179 179 180 /* Parameter p FilterGraphUnknown*/181 182 /* 60 */ NdrFcShort( 0x b ), /* Flags: must size, must free, in,*/180 /* Parameter pfTime */ 181 182 /* 60 */ NdrFcShort( 0x2150 ), /* Flags: out, base type, simple ref, srv alloc size=8 */ 183 183 /* 62 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 184 /* 64 */ NdrFcShort( 0x6 ), /* Type Offset=6 */ 184 /* 64 */ 0xc, /* FC_DOUBLE */ 185 0x0, /* 0 */ 185 186 186 187 /* Return value */ … … 192 193 193 194 /* Procedure get_Text */ 195 196 197 /* Procedure get_FriendlyName */ 194 198 195 199 /* 72 */ 0x33, /* FC_AUTO_HANDLE */ … … 210 214 /* Parameter psText */ 211 215 216 217 /* Parameter psFriendlyName */ 218 212 219 /* 96 */ NdrFcShort( 0x2113 ), /* Flags: must size, must free, out, simple ref, srv alloc size=8 */ 213 220 /* 98 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 214 /* 100 */ NdrFcShort( 0x36 ), /* Type Offset=54 */ 221 /* 100 */ NdrFcShort( 0x20 ), /* Type Offset=32 */ 222 223 /* Return value */ 224 215 225 216 226 /* Return value */ … … 221 231 0x0, /* 0 */ 222 232 223 /* Procedure DoPropertyFrameModal*/233 /* Procedure put_FriendlyName */ 224 234 225 235 /* 108 */ 0x33, /* FC_AUTO_HANDLE */ … … 228 238 /* 114 */ NdrFcShort( 0xa ), /* 10 */ 229 239 /* 116 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 230 /* 118 */ NdrFcShort( 0x 8 ), /* 8*/240 /* 118 */ NdrFcShort( 0x0 ), /* 0 */ 231 241 /* 120 */ NdrFcShort( 0x8 ), /* 8 */ 232 /* 122 */ 0x4 4, /* Oi2 Flags:has return, has ext, */242 /* 122 */ 0x46, /* Oi2 Flags: clt must size, has return, has ext, */ 233 243 0x2, /* 2 */ 234 244 /* 124 */ 0x8, /* 8 */ 235 0x 1, /* Ext Flags: new corr desc, */245 0x5, /* Ext Flags: new corr desc, srv corr check, */ 236 246 /* 126 */ NdrFcShort( 0x0 ), /* 0 */ 237 /* 128 */ NdrFcShort( 0x 0 ), /* 0*/247 /* 128 */ NdrFcShort( 0x1 ), /* 1 */ 238 248 /* 130 */ NdrFcShort( 0x0 ), /* 0 */ 239 249 240 /* Parameter nParentWindowHandle */241 242 /* 132 */ NdrFcShort( 0x 48 ), /* Flags: in, base type, */250 /* Parameter sFriendlyName */ 251 252 /* 132 */ NdrFcShort( 0x8b ), /* Flags: must size, must free, in, by val, */ 243 253 /* 134 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 244 /* 136 */ 0x8, /* FC_LONG */ 245 0x0, /* 0 */ 254 /* 136 */ NdrFcShort( 0x32 ), /* Type Offset=50 */ 246 255 247 256 /* Return value */ … … 250 259 /* 140 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 251 260 /* 142 */ 0x8, /* FC_LONG */ 261 0x0, /* 0 */ 262 263 /* Procedure get_FilterGraph */ 264 265 /* 144 */ 0x33, /* FC_AUTO_HANDLE */ 266 0x6c, /* Old Flags: object, Oi2 */ 267 /* 146 */ NdrFcLong( 0x0 ), /* 0 */ 268 /* 150 */ NdrFcShort( 0x7 ), /* 7 */ 269 /* 152 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 270 /* 154 */ NdrFcShort( 0x0 ), /* 0 */ 271 /* 156 */ NdrFcShort( 0x8 ), /* 8 */ 272 /* 158 */ 0x45, /* Oi2 Flags: srv must size, has return, has ext, */ 273 0x2, /* 2 */ 274 /* 160 */ 0x8, /* 8 */ 275 0x1, /* Ext Flags: new corr desc, */ 276 /* 162 */ NdrFcShort( 0x0 ), /* 0 */ 277 /* 164 */ NdrFcShort( 0x0 ), /* 0 */ 278 /* 166 */ NdrFcShort( 0x0 ), /* 0 */ 279 280 /* Parameter ppFilterGraphUnknown */ 281 282 /* 168 */ NdrFcShort( 0x13 ), /* Flags: must size, must free, out, */ 283 /* 170 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 284 /* 172 */ NdrFcShort( 0x3c ), /* Type Offset=60 */ 285 286 /* Return value */ 287 288 /* 174 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 289 /* 176 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 290 /* 178 */ 0x8, /* FC_LONG */ 291 0x0, /* 0 */ 292 293 /* Procedure put_FilterGraph */ 294 295 /* 180 */ 0x33, /* FC_AUTO_HANDLE */ 296 0x6c, /* Old Flags: object, Oi2 */ 297 /* 182 */ NdrFcLong( 0x0 ), /* 0 */ 298 /* 186 */ NdrFcShort( 0x8 ), /* 8 */ 299 /* 188 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 300 /* 190 */ NdrFcShort( 0x0 ), /* 0 */ 301 /* 192 */ NdrFcShort( 0x8 ), /* 8 */ 302 /* 194 */ 0x46, /* Oi2 Flags: clt must size, has return, has ext, */ 303 0x2, /* 2 */ 304 /* 196 */ 0x8, /* 8 */ 305 0x1, /* Ext Flags: new corr desc, */ 306 /* 198 */ NdrFcShort( 0x0 ), /* 0 */ 307 /* 200 */ NdrFcShort( 0x0 ), /* 0 */ 308 /* 202 */ NdrFcShort( 0x0 ), /* 0 */ 309 310 /* Parameter pFilterGraphUnknown */ 311 312 /* 204 */ NdrFcShort( 0xb ), /* Flags: must size, must free, in, */ 313 /* 206 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 314 /* 208 */ NdrFcShort( 0x40 ), /* Type Offset=64 */ 315 316 /* Return value */ 317 318 /* 210 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 319 /* 212 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 320 /* 214 */ 0x8, /* FC_LONG */ 321 0x0, /* 0 */ 322 323 /* Procedure DoPropertyFrameModal */ 324 325 /* 216 */ 0x33, /* FC_AUTO_HANDLE */ 326 0x6c, /* Old Flags: object, Oi2 */ 327 /* 218 */ NdrFcLong( 0x0 ), /* 0 */ 328 /* 222 */ NdrFcShort( 0xa ), /* 10 */ 329 /* 224 */ NdrFcShort( 0xc ), /* x86 Stack size/offset = 12 */ 330 /* 226 */ NdrFcShort( 0x8 ), /* 8 */ 331 /* 228 */ NdrFcShort( 0x8 ), /* 8 */ 332 /* 230 */ 0x44, /* Oi2 Flags: has return, has ext, */ 333 0x2, /* 2 */ 334 /* 232 */ 0x8, /* 8 */ 335 0x1, /* Ext Flags: new corr desc, */ 336 /* 234 */ NdrFcShort( 0x0 ), /* 0 */ 337 /* 236 */ NdrFcShort( 0x0 ), /* 0 */ 338 /* 238 */ NdrFcShort( 0x0 ), /* 0 */ 339 340 /* Parameter nParentWindowHandle */ 341 342 /* 240 */ NdrFcShort( 0x48 ), /* Flags: in, base type, */ 343 /* 242 */ NdrFcShort( 0x4 ), /* x86 Stack size/offset = 4 */ 344 /* 244 */ 0x8, /* FC_LONG */ 345 0x0, /* 0 */ 346 347 /* Return value */ 348 349 /* 246 */ NdrFcShort( 0x70 ), /* Flags: out, return, base type, */ 350 /* 248 */ NdrFcShort( 0x8 ), /* x86 Stack size/offset = 8 */ 351 /* 250 */ 0x8, /* FC_LONG */ 252 352 0x0, /* 0 */ 253 353 … … 262 362 NdrFcShort( 0x0 ), /* 0 */ 263 363 /* 2 */ 364 0x11, 0x4, /* FC_RP [alloced_on_stack] */ 365 /* 4 */ NdrFcShort( 0x1c ), /* Offset= 28 (32) */ 366 /* 6 */ 367 0x13, 0x0, /* FC_OP */ 368 /* 8 */ NdrFcShort( 0xe ), /* Offset= 14 (22) */ 369 /* 10 */ 370 0x1b, /* FC_CARRAY */ 371 0x1, /* 1 */ 372 /* 12 */ NdrFcShort( 0x2 ), /* 2 */ 373 /* 14 */ 0x9, /* Corr desc: FC_ULONG */ 374 0x0, /* */ 375 /* 16 */ NdrFcShort( 0xfffc ), /* -4 */ 376 /* 18 */ NdrFcShort( 0x1 ), /* Corr flags: early, */ 377 /* 20 */ 0x6, /* FC_SHORT */ 378 0x5b, /* FC_END */ 379 /* 22 */ 380 0x17, /* FC_CSTRUCT */ 381 0x3, /* 3 */ 382 /* 24 */ NdrFcShort( 0x8 ), /* 8 */ 383 /* 26 */ NdrFcShort( 0xfff0 ), /* Offset= -16 (10) */ 384 /* 28 */ 0x8, /* FC_LONG */ 385 0x8, /* FC_LONG */ 386 /* 30 */ 0x5c, /* FC_PAD */ 387 0x5b, /* FC_END */ 388 /* 32 */ 0xb4, /* FC_USER_MARSHAL */ 389 0x83, /* 131 */ 390 /* 34 */ NdrFcShort( 0x0 ), /* 0 */ 391 /* 36 */ NdrFcShort( 0x4 ), /* 4 */ 392 /* 38 */ NdrFcShort( 0x0 ), /* 0 */ 393 /* 40 */ NdrFcShort( 0xffde ), /* Offset= -34 (6) */ 394 /* 42 */ 395 0x11, 0xc, /* FC_RP [alloced_on_stack] [simple_pointer] */ 396 /* 44 */ 0xc, /* FC_DOUBLE */ 397 0x5c, /* FC_PAD */ 398 /* 46 */ 399 0x12, 0x0, /* FC_UP */ 400 /* 48 */ NdrFcShort( 0xffe6 ), /* Offset= -26 (22) */ 401 /* 50 */ 0xb4, /* FC_USER_MARSHAL */ 402 0x83, /* 131 */ 403 /* 52 */ NdrFcShort( 0x0 ), /* 0 */ 404 /* 54 */ NdrFcShort( 0x4 ), /* 4 */ 405 /* 56 */ NdrFcShort( 0x0 ), /* 0 */ 406 /* 58 */ NdrFcShort( 0xfff4 ), /* Offset= -12 (46) */ 407 /* 60 */ 264 408 0x11, 0x10, /* FC_RP [pointer_deref] */ 265 /* 4 */ NdrFcShort( 0x2 ), /* Offset= 2 (6) */266 /* 6*/409 /* 62 */ NdrFcShort( 0x2 ), /* Offset= 2 (64) */ 410 /* 64 */ 267 411 0x2f, /* FC_IP */ 268 412 0x5a, /* FC_CONSTANT_IID */ 269 /* 8*/ NdrFcLong( 0x0 ), /* 0 */270 /* 12*/ NdrFcShort( 0x0 ), /* 0 */271 /* 14*/ NdrFcShort( 0x0 ), /* 0 */272 /* 16*/ 0xc0, /* 192 */273 0x0, /* 0 */ 274 /* 18*/ 0x0, /* 0 */275 0x0, /* 0 */ 276 /* 20*/ 0x0, /* 0 */277 0x0, /* 0 */ 278 /* 22*/ 0x0, /* 0 */413 /* 66 */ NdrFcLong( 0x0 ), /* 0 */ 414 /* 70 */ NdrFcShort( 0x0 ), /* 0 */ 415 /* 72 */ NdrFcShort( 0x0 ), /* 0 */ 416 /* 74 */ 0xc0, /* 192 */ 417 0x0, /* 0 */ 418 /* 76 */ 0x0, /* 0 */ 419 0x0, /* 0 */ 420 /* 78 */ 0x0, /* 0 */ 421 0x0, /* 0 */ 422 /* 80 */ 0x0, /* 0 */ 279 423 0x46, /* 70 */ 280 /* 24 */281 0x11, 0x4, /* FC_RP [alloced_on_stack] */282 /* 26 */ NdrFcShort( 0x1c ), /* Offset= 28 (54) */283 /* 28 */284 0x13, 0x0, /* FC_OP */285 /* 30 */ NdrFcShort( 0xe ), /* Offset= 14 (44) */286 /* 32 */287 0x1b, /* FC_CARRAY */288 0x1, /* 1 */289 /* 34 */ NdrFcShort( 0x2 ), /* 2 */290 /* 36 */ 0x9, /* Corr desc: FC_ULONG */291 0x0, /* */292 /* 38 */ NdrFcShort( 0xfffc ), /* -4 */293 /* 40 */ NdrFcShort( 0x1 ), /* Corr flags: early, */294 /* 42 */ 0x6, /* FC_SHORT */295 0x5b, /* FC_END */296 /* 44 */297 0x17, /* FC_CSTRUCT */298 0x3, /* 3 */299 /* 46 */ NdrFcShort( 0x8 ), /* 8 */300 /* 48 */ NdrFcShort( 0xfff0 ), /* Offset= -16 (32) */301 /* 50 */ 0x8, /* FC_LONG */302 0x8, /* FC_LONG */303 /* 52 */ 0x5c, /* FC_PAD */304 0x5b, /* FC_END */305 /* 54 */ 0xb4, /* FC_USER_MARSHAL */306 0x83, /* 131 */307 /* 56 */ NdrFcShort( 0x0 ), /* 0 */308 /* 58 */ NdrFcShort( 0x4 ), /* 4 */309 /* 60 */ NdrFcShort( 0x0 ), /* 0 */310 /* 62 */ NdrFcShort( 0xffde ), /* Offset= -34 (28) */311 424 312 425 0x0 … … 346 459 (unsigned short) -1, 347 460 (unsigned short) -1, 348 0 461 0, 462 36, 463 72, 464 108 349 465 }; 350 466 … … 370 486 0, 371 487 0}; 372 CINTERFACE_PROXY_VTABLE( 7) _ISpyProxyVtbl =373 { 374 0,488 CINTERFACE_PROXY_VTABLE(11) _ISpyProxyVtbl = 489 { 490 &ISpy_ProxyInfo, 375 491 &IID_ISpy, 376 492 IUnknown_QueryInterface_Proxy, … … 380 496 0 /* IDispatch::GetTypeInfo */ , 381 497 0 /* IDispatch::GetIDsOfNames */ , 382 0 /* IDispatch_Invoke_Proxy */ 498 0 /* IDispatch_Invoke_Proxy */ , 499 (void *) (INT_PTR) -1 /* ISpy::get_MonikerDisplayName */ , 500 (void *) (INT_PTR) -1 /* ISpy::get_CreationTime */ , 501 (void *) (INT_PTR) -1 /* ISpy::get_FriendlyName */ , 502 (void *) (INT_PTR) -1 /* ISpy::put_FriendlyName */ 383 503 }; 384 504 … … 389 509 STUB_FORWARDING_FUNCTION, 390 510 STUB_FORWARDING_FUNCTION, 391 STUB_FORWARDING_FUNCTION 511 STUB_FORWARDING_FUNCTION, 512 NdrStubCall2, 513 NdrStubCall2, 514 NdrStubCall2, 515 NdrStubCall2 392 516 }; 393 517 … … 396 520 &IID_ISpy, 397 521 &ISpy_ServerInfo, 398 7,522 11, 399 523 &ISpy_table[-3], 400 524 CStdStubBuffer_DELEGATING_METHODS … … 544 668 (unsigned short) -1, 545 669 (unsigned short) -1, 546 0,547 36,670 144, 671 180, 548 672 72, 549 108673 216 550 674 }; 551 675 -
trunk/DirectShowSpy/FilterGraphHelper.h
r240 r242 11 11 #include "AboutDialog.h" 12 12 #include "..\..\Repository-Private\Utilities\EmailTools\Message.h" 13 14 INT_PTR DoFilterGraphListPropertySheetModal(HWND hParentWindow); 13 15 14 16 //////////////////////////////////////////////////////////// … … 51 53 class CPropertyFrameDialog : 52 54 public CDialogImpl<CPropertyFrameDialog>, 53 public CDialogResize<CPropertyFrameDialog> 55 public CDialogResize<CPropertyFrameDialog>, 56 public CDialogWithAcceleratorsT<CPropertyFrameDialog> 54 57 { 55 58 public: … … 68 71 COMMAND_ID_HANDLER_EX(IDCANCEL, OnCancel) 69 72 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_PROPERTYFRAME_APPLY, OnApply) 73 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENGSN, OnActionCommand) 74 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENGE, OnActionCommand) 75 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENLIST, OnActionCommand) 70 76 REFLECT_NOTIFICATIONS() 71 77 END_MSG_MAP() … … 169 175 pMessage; 170 176 return E_NOTIMPL; 177 } 178 }; 179 180 //////////////////////////////////////////////////// 181 // CActionDialog 182 183 class CActionDialog : 184 public CDialogImpl<CActionDialog>, 185 public CDialogResize<CActionDialog> 186 { 187 public: 188 enum { IDD = IDD_FILTERGRAPHHELPER_ACTION }; 189 190 BEGIN_MSG_MAP_EX(CActionDialog) 191 //CHAIN_MSG_MAP(CDialogImpl<CActionDialog>) 192 CHAIN_MSG_MAP(CDialogResize<CActionDialog>) 193 MSG_WM_INITDIALOG(OnInitDialog) 194 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_SAVEAS, OnSaveAs) 195 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENGSN, OnOpenGsn) 196 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENGE, OnOpenGe) 197 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHHELPER_ACTION_OPENLIST, OnOpenList) 198 REFLECT_NOTIFICATIONS() 199 END_MSG_MAP() 200 201 BEGIN_DLGRESIZE_MAP(CActionDialog) 202 //DLGRESIZE_CONTROL(IDC_FILTERGRAPHHELPER_ACTION_, DLSZ_SIZE_X | DLSZ_SIZE_Y) 203 END_DLGRESIZE_MAP() 204 205 private: 206 CPropertyFrameDialog* m_pOwner; 207 BOOL m_bActivating; 208 CStatic m_TitleStatic; 209 CFont m_TitleFont; 210 CButton m_SaveAsButton; 211 CRoHyperStatic m_SaveAsDescriptionStatic; 212 CButton m_OpenGsnButton; 213 CRoHyperStatic m_OpenGsnDescriptionStatic; 214 CButton m_OpenGeButton; 215 CRoHyperStatic m_OpenGeDescriptionStatic; 216 CButton m_OpenListButton; 217 CRoHyperStatic m_OpenListDescriptionStatic; 218 CStringW m_sFilterGraphMonikerDisplayName; 219 CRoMapT<INT_PTR, BOOL> m_ChangeMap; 220 221 public: 222 // CActionDialog 223 224 // Window Message Handler 225 LRESULT OnInitDialog(HWND, LPARAM lParam) 226 { 227 m_pOwner = (CPropertyFrameDialog*) lParam; 228 m_bActivating = TRUE; 229 _ATLTRY 230 { 231 CWaitCursor WaitCursor; 232 m_TitleStatic = GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_TITLE); 233 CreateTitleFont(m_TitleFont, m_TitleStatic); 234 m_SaveAsButton = GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_SAVEAS); 235 _W(m_SaveAsDescriptionStatic.SubclassWindow(GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_SAVEASDESCRIPTION))); 236 m_OpenGsnButton = GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENGSN); 237 _W(m_OpenGsnDescriptionStatic.SubclassWindow(GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENGSNDESCRIPTION))); 238 m_OpenGeButton = GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENGE); 239 _W(m_OpenGeDescriptionStatic.SubclassWindow(GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENGEDESCRIPTION))); 240 m_OpenListButton = GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENLIST); 241 _W(m_OpenListDescriptionStatic.SubclassWindow(GetDlgItem(IDC_FILTERGRAPHHELPER_ACTION_OPENLISTDESCRIPTION))); 242 //DlgResize_Init(FALSE, FALSE); 243 _ATLTRY 244 { 245 m_sFilterGraphMonikerDisplayName.Empty(); 246 const CComQIPtr<ISpy> pSpy = m_pOwner->m_Owner.GetFilterGraph(); 247 if(pSpy) 248 { 249 CComBSTR sFilterGraphMonikerDisplayName; 250 __C(pSpy->get_MonikerDisplayName(&sFilterGraphMonikerDisplayName)); 251 m_sFilterGraphMonikerDisplayName = sFilterGraphMonikerDisplayName; 252 } 253 } 254 _ATLCATCHALL() 255 { 256 _Z_EXCEPTION(); 257 } 258 const BOOL bMonikerDisplayNameAvailable = !m_sFilterGraphMonikerDisplayName.IsEmpty(); 259 m_OpenGsnButton.EnableWindow(bMonikerDisplayNameAvailable); 260 m_OpenGeButton.EnableWindow(bMonikerDisplayNameAvailable); 261 m_bActivating = FALSE; 262 } 263 _ATLCATCH(Exception) 264 { 265 for(CWindow Window = GetWindow(GW_CHILD); Window; Window = Window.GetWindow(GW_HWNDNEXT)) 266 Window.EnableWindow(FALSE); 267 AtlExceptionMessageBox(m_hWnd, Exception); 268 } 269 return TRUE; 270 } 271 LRESULT OnSaveAs(UINT, INT, HWND) 272 { 273 CPath sPath; 274 static const COMDLG_FILTERSPEC g_pFilter[] = 275 { 276 { _T("GraphEdit Files"), _T("*.grf") }, 277 { _T("All Files"), _T("*.*") }, 278 }; 279 if(GetOsVersion() >= GetWinVistaOsVersion()) 280 { 281 CShellFileSaveDialog Dialog(NULL, FOS_OVERWRITEPROMPT | FOS_FORCEFILESYSTEM | FOS_PATHMUSTEXIST, _T("grf"), g_pFilter, DIM(g_pFilter)); 282 if(Dialog.DoModal(m_hWnd) != IDOK) 283 return 0; 284 CString sPathString; 285 __C(Dialog.GetFilePath(sPathString)); 286 sPath = (LPCTSTR) sPathString; 287 } else 288 { 289 CString sFilter; 290 CFileDialog Dialog(FALSE, _T("grf"), NULL, OFN_OVERWRITEPROMPT | OFN_HIDEREADONLY | OFN_PATHMUSTEXIST | OFN_EXPLORER | OFN_ENABLESIZING, GetLegacyFilter(g_pFilter, sFilter)); 291 if(Dialog.DoModal(m_hWnd) != IDOK) 292 return 0; 293 sPath = Dialog.m_szFileName; 294 } 295 #pragma region Save 296 // NOTE: See http://msdn.microsoft.com/en-us/library/windows/desktop/dd377551 297 const CComQIPtr<IPersistStream> pPersistStream = m_pOwner->m_Owner.GetFilterGraph(); 298 __D(pPersistStream, E_NOINTERFACE); 299 CComPtr<IStorage> pStorage; 300 { 301 __C(StgCreateDocfile(CStringW(sPath), STGM_CREATE | STGM_TRANSACTED | STGM_READWRITE | STGM_SHARE_EXCLUSIVE, 0, &pStorage)); 302 CComPtr<IStream> pStream; 303 __C(pStorage->CreateStream(L"ActiveMovieGraph", STGM_WRITE | STGM_CREATE | STGM_SHARE_EXCLUSIVE, 0, 0, &pStream)); 304 __C(pPersistStream->Save(pStream, TRUE)); 305 } 306 __C(pStorage->Commit(STGC_DEFAULT)); 307 #pragma endregion 308 MessageBeep(MB_OK); 309 return 0; 310 } 311 LRESULT OnOpenGsn(UINT, INT, HWND) 312 { 313 OpenMonikerWithGsn(m_sFilterGraphMonikerDisplayName, m_hWnd); 314 return 0; 315 } 316 LRESULT OnOpenGe(UINT, INT, HWND) 317 { 318 OpenMonikerWithGe(m_sFilterGraphMonikerDisplayName, m_hWnd); 319 return 0; 320 } 321 LRESULT OnOpenList(UINT, INT, HWND) 322 { 323 DoFilterGraphListPropertySheetModal(m_hWnd); 324 return 0; 171 325 } 172 326 }; … … 426 580 CWaitCursor WaitCursor; 427 581 m_TitleStatic = GetDlgItem(IDC_FILTERGRAPHHELPER_EMAIL_TITLE); 428 CLogFont LogFont; 429 LogFont.SetHeight(12, CClientDC(m_hWnd)); 430 LogFont.lfWeight = FW_BOLD; 431 _tcsncpy_s(LogFont.lfFaceName, _T("Verdana"), _TRUNCATE); 432 _W(m_TitleFont.CreateFontIndirect(&LogFont)); 433 m_TitleStatic.SetFont(m_TitleFont); 582 CreateTitleFont(m_TitleFont, m_TitleStatic); 434 583 m_FromEdit = GetDlgItem(IDC_FILTERGRAPHHELPER_EMAIL_FROM); 435 584 m_ToEdit = GetDlgItem(IDC_FILTERGRAPHHELPER_EMAIL_TO); … … 561 710 TYPE_FILTER, 562 711 TYPE_FILTERPROPERTYPAGE, 712 TYPE_ACTION, 563 713 TYPE_EMAIL, 564 714 } TYPE; … … 615 765 CRoTreeViewT<CData, CRoListControlDataTraitsT> m_TreeView; 616 766 CTreeItem m_FiltersItem; 767 CTreeItem m_ActionItem; 617 768 CTreeItem m_EmailItem; 618 769 CTabCtrl m_Tab; … … 624 775 CButton m_ApplyButton; 625 776 CObjectPtr<CPropertyPageSite> m_pCurrentSite; 777 CActionDialog m_ActionDialog; 626 778 CEmailDialog m_EmailDialog; 779 780 static VOID CreateTitleFont(CFont& Font, HWND hStaticWindow = NULL) 781 { 782 _A(!Font); 783 CLogFont LogFont; 784 LogFont.SetHeight(12); 785 LogFont.lfWeight = FW_BOLD; 786 _tcsncpy_s(LogFont.lfFaceName, _T("Verdana"), _TRUNCATE); 787 _W(Font.CreateFontIndirect(&LogFont)); 788 if(hStaticWindow) 789 CStatic(hStaticWindow).SetFont(Font); 790 } 627 791 628 792 public: … … 696 860 m_FiltersItem.m_pTreeView = &m_TreeView; 697 861 #pragma endregion 698 CTreeItem EmailItem = m_TreeView.InsertItem(NULL, FiltersItem, CData(CData::TYPE_EMAIL), _T("Email")); 862 CTreeItem ActionItem = m_TreeView.InsertItem(NULL, FiltersItem, CData(CData::TYPE_ACTION), _T("Action")); 863 m_ActionItem.m_hTreeItem = ActionItem; 864 m_ActionItem.m_pTreeView = &m_TreeView; 865 CTreeItem EmailItem = m_TreeView.InsertItem(NULL, ActionItem, CData(CData::TYPE_EMAIL), _T("Email")); 699 866 m_EmailItem.m_hTreeItem = EmailItem; 700 867 m_EmailItem.m_pTreeView = &m_TreeView; … … 720 887 HandleStatusChange(m_pCurrentSite); 721 888 } 889 INT_PTR DoModal(HWND hParentWindow = GetActiveWindow()) 890 { 891 return CDialogWithAccelerators::DoModal(hParentWindow); 892 } 722 893 723 894 // CDialogResize … … 728 899 if(m_pCurrentSite && m_pCurrentSite->m_pPropertyPage) 729 900 _V(m_pCurrentSite->m_pPropertyPage->Move(Position)); 901 _W(m_ActionDialog.SetWindowPos(NULL, Position, SWP_NOZORDER | SWP_NOACTIVATE)); 730 902 _W(m_EmailDialog.SetWindowPos(NULL, Position, SWP_NOZORDER | SWP_NOACTIVATE)); 731 903 } … … 754 926 _W(Menu.AppendMenu(MF_STRING, ID_APP_ABOUT, _T("&About..."))); 755 927 #pragma endregion 928 #pragma region Icon 929 SetIcon(AtlLoadIconImage(IDI_MODULE, LR_COLOR, GetSystemMetrics(SM_CXICON), GetSystemMetrics(SM_CYICON)), TRUE); 930 SetIcon(AtlLoadIconImage(IDI_MODULE, LR_COLOR, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON)), FALSE); 931 #pragma endregion 756 932 m_TreeView.Initialize(GetDlgItem(IDC_FILTERGRAPHHELPER_PROPERTYFRAME_TREE)); 757 933 m_TextEdit = GetDlgItem(IDC_FILTERGRAPHHELPER_PROPERTYFRAME_TEXT); … … 769 945 m_CancelButton = GetDlgItem(IDCANCEL); 770 946 m_ApplyButton = GetDlgItem(IDC_FILTERGRAPHHELPER_PROPERTYFRAME_APPLY); 947 __E(m_ActionDialog.Create(m_hWnd, (LPARAM) this)); 771 948 __E(m_EmailDialog.Create(m_hWnd, (LPARAM) this)); 772 949 DlgResize_Init(TRUE); … … 816 993 { 817 994 CData& Data = m_TreeView.GetItemData(TreeItem); 995 if(Data.m_Type != CData::TYPE_ACTION) 996 m_ActionDialog.ShowWindow(SW_HIDE); 818 997 if(Data.m_Type != CData::TYPE_EMAIL) 819 998 m_EmailDialog.ShowWindow(SW_HIDE); 820 #pragma endregion821 999 if(Data.m_pBaseFilter) 822 1000 { … … 920 1098 switch(Data.m_Type) 921 1099 { 1100 #pragma region TYPE_ACTION 1101 case CData::TYPE_ACTION: 1102 m_TextEdit.ShowWindow(SW_HIDE); 1103 _W(m_ActionDialog.SetWindowPos(NULL, GetTextEditPosition(), SWP_NOZORDER | SWP_SHOWWINDOW)); 1104 break; 1105 #pragma endregion 922 1106 #pragma region TYPE_EMAIL 923 1107 case CData::TYPE_EMAIL: … … 929 1113 m_TextEdit.ShowWindow(SW_SHOW); 930 1114 m_TextEdit.SetValue(m_Owner.GetText()); 1115 m_ActionDialog.ShowWindow(SW_HIDE); 931 1116 m_EmailDialog.ShowWindow(SW_HIDE); 932 1117 } … … 937 1122 HideCurrentSite(); 938 1123 m_TextEdit.ShowWindow(SW_HIDE); 1124 m_ActionDialog.ShowWindow(SW_HIDE); 939 1125 m_EmailDialog.ShowWindow(SW_HIDE); 940 1126 m_ApplyButton.EnableWindow(FALSE); … … 1019 1205 } 1020 1206 return 0; 1207 } 1208 LRESULT OnActionCommand(UINT, INT nIdentifier, HWND) 1209 { 1210 return m_ActionDialog.SendMessage(WM_COMMAND, nIdentifier); 1021 1211 } 1022 1212 }; … … 1711 1901 return GetText(m_pFilterGraph); 1712 1902 } 1903 static LPCTSTR GetPlatformName() 1904 { 1905 #if defined(_WIN64) 1906 return _T("x64"); 1907 #else 1908 return _T("Win32"); 1909 #endif // defined(_WIN64) 1910 } 1911 template <SIZE_T t_nItemCount> 1912 static CString& GetLegacyFilter(const COMDLG_FILTERSPEC (&pItems)[t_nItemCount], CString& sFilter) 1913 { 1914 _A(sFilter.IsEmpty()); 1915 for(SIZE_T nIndex = 0; nIndex < t_nItemCount; nIndex++) 1916 { 1917 const COMDLG_FILTERSPEC& Item = pItems[nIndex]; 1918 sFilter += AtlFormatString(_T("%s (%s)|%s|"), Item.pszName, Item.pszSpec, Item.pszSpec); 1919 } 1920 sFilter.Replace(_T('|'), 0); 1921 return sFilter; 1922 } 1923 static BOOL OpenMonikerWithGsn(LPCWSTR pszMonikerDisplayName, HWND hParentWindow = GetActiveWindow()) 1924 { 1925 _A(pszMonikerDisplayName); 1926 static const LPCTSTR g_pszValueName = _T("GraphStudioNext Path"); 1927 static const LPCTSTR g_pszFileName = _T("graphstudionext.exe"); 1928 const CString sValueName = AtlFormatString(_T("%s (%s)"), g_pszValueName, GetPlatformName()); 1929 CString sPath = _RegKeyHelper::QueryStringValue(HKEY_CURRENT_USER, REGISTRY_ROOT, sValueName); 1930 if(!FileExists(sPath)) 1931 sPath.Empty(); 1932 #pragma region Current Directory 1933 if(sPath.IsEmpty()) 1934 { 1935 sPath = (LPCTSTR) Combine(GetPathDirectory(GetModulePath()), g_pszFileName); 1936 if(!FileExists(sPath)) 1937 sPath.Empty(); 1938 } 1939 #pragma endregion 1940 #pragma region Application Registry 1941 if(sPath.IsEmpty()) 1942 { 1943 #if defined(_WIN64) 1944 static const LPCTSTR g_pszValueName = _T("exeLocation64"); 1945 #else 1946 static const LPCTSTR g_pszValueName = _T("exeLocation"); 1947 #endif // defined(_WIN64) 1948 sPath = _RegKeyHelper::QueryStringValue(HKEY_CURRENT_USER, _T("Software\\MONOGRAM\\GraphStudioNext"), g_pszValueName); 1949 if(!FileExists(sPath)) 1950 sPath.Empty(); 1951 } 1952 #pragma endregion 1953 if(sPath.IsEmpty()) 1954 { 1955 #pragma region Prompt 1956 static const COMDLG_FILTERSPEC g_pFilter[] = 1957 { 1958 { _T("Executable Files"), _T("*.exe") }, 1959 { _T("All Files"), _T("*.*") }, 1960 }; 1961 if(GetOsVersion() >= GetWinVistaOsVersion()) 1962 { 1963 CShellFileOpenDialog Dialog(g_pszFileName, FOS_FORCEFILESYSTEM | FOS_FILEMUSTEXIST, _T("exe"), g_pFilter, DIM(g_pFilter)); 1964 if(Dialog.DoModal(hParentWindow) != IDOK) 1965 return FALSE; 1966 __C(Dialog.GetFilePath(sPath)); 1967 } else 1968 { 1969 CString sFilter; 1970 CFileDialog Dialog(TRUE, _T("exe"), NULL, OFN_HIDEREADONLY | OFN_FILEMUSTEXIST | OFN_EXPLORER | OFN_ENABLESIZING, GetLegacyFilter(g_pFilter, sFilter)); 1971 if(Dialog.DoModal(hParentWindow) != IDOK) 1972 return FALSE; 1973 sPath = Dialog.m_szFileName; 1974 } 1975 #pragma endregion 1976 _RegKeyHelper::SetStringValue(HKEY_CURRENT_USER, REGISTRY_ROOT, sValueName, sPath); 1977 } 1978 CWaitCursor WaitCursor; 1979 CString sParameters = AtlFormatString(_T("-a \"%ls\""), pszMonikerDisplayName); 1980 SHELLEXECUTEINFO Infomation; 1981 ZeroMemory(&Infomation, sizeof Infomation); 1982 Infomation.cbSize = sizeof Infomation; 1983 Infomation.lpFile = sPath; 1984 Infomation.lpParameters = sParameters; 1985 Infomation.nShow = SW_SHOWNORMAL; 1986 __E(ShellExecuteEx(&Infomation)); 1987 return TRUE; 1988 } 1989 static BOOL OpenMonikerWithGe(LPCWSTR pszMonikerDisplayName, HWND hParentWindow = GetActiveWindow()) 1990 { 1991 static const LPCTSTR g_pszValueName = _T("GraphEdit Path"); 1992 static const LPCTSTR g_pszFileName = _T("graphedt.exe"); 1993 const CString sValueName = AtlFormatString(_T("%s (%s)"), g_pszValueName, GetPlatformName()); 1994 CString sPath = _RegKeyHelper::QueryStringValue(HKEY_CURRENT_USER, REGISTRY_ROOT, sValueName); 1995 if(!FileExists(sPath)) 1996 sPath.Empty(); 1997 #pragma region Current Directory 1998 if(sPath.IsEmpty()) 1999 { 2000 sPath = (LPCTSTR) Combine(GetPathDirectory(GetModulePath()), g_pszFileName); 2001 if(!FileExists(sPath)) 2002 sPath.Empty(); 2003 } 2004 #pragma endregion 2005 // SUGG: Look for Windows SDK 2006 if(sPath.IsEmpty()) 2007 { 2008 #pragma region Prompt 2009 static const COMDLG_FILTERSPEC g_pFilter[] = 2010 { 2011 { _T("Executable Files"), _T("*.exe") }, 2012 { _T("All Files"), _T("*.*") }, 2013 }; 2014 if(GetOsVersion() >= GetWinVistaOsVersion()) 2015 { 2016 CShellFileOpenDialog Dialog(g_pszFileName, FOS_FORCEFILESYSTEM | FOS_FILEMUSTEXIST, _T("exe"), g_pFilter, DIM(g_pFilter)); 2017 if(Dialog.DoModal(hParentWindow) != IDOK) 2018 return FALSE; 2019 __C(Dialog.GetFilePath(sPath)); 2020 } else 2021 { 2022 CString sFilter; 2023 CFileDialog Dialog(TRUE, _T("exe"), NULL, OFN_HIDEREADONLY | OFN_FILEMUSTEXIST | OFN_EXPLORER | OFN_ENABLESIZING, GetLegacyFilter(g_pFilter, sFilter)); 2024 if(Dialog.DoModal(hParentWindow) != IDOK) 2025 return FALSE; 2026 sPath = Dialog.m_szFileName; 2027 } 2028 #pragma endregion 2029 _RegKeyHelper::SetStringValue(HKEY_CURRENT_USER, REGISTRY_ROOT, sValueName, sPath); 2030 } 2031 CStringW sFilterGraphMonikerDisplayName = pszMonikerDisplayName; 2032 const INT nSeparatorPosition = sFilterGraphMonikerDisplayName.Find(L';'); 2033 if(nSeparatorPosition >= 0) 2034 sFilterGraphMonikerDisplayName = sFilterGraphMonikerDisplayName.Left(nSeparatorPosition); 2035 CWaitCursor WaitCursor; 2036 CString sParameters = AtlFormatString(_T("-a %ls"), sFilterGraphMonikerDisplayName); 2037 SHELLEXECUTEINFO Infomation; 2038 ZeroMemory(&Infomation, sizeof Infomation); 2039 Infomation.cbSize = sizeof Infomation; 2040 Infomation.lpFile = sPath; 2041 Infomation.lpParameters = sParameters; 2042 Infomation.nShow = SW_SHOWNORMAL; 2043 __E(ShellExecuteEx(&Infomation)); 2044 return TRUE; 2045 } 1713 2046 1714 2047 // IFilterGraphHelper -
trunk/DirectShowSpy/FilterGraphList.h
r231 r242 18 18 // CFilterGraphListPropertySheet 19 19 20 INT_PTR DoFilterGraphListPropertySheetModal(HWND hParentWindow = GetActiveWindow()); 21 20 22 class CFilterGraphListPropertySheet : 21 public CSizablePropertySheetT<CFilterGraphListPropertySheet> 23 public CSizablePropertySheetT<CFilterGraphListPropertySheet>, 24 public CPropertySheetWithAcceleratorsT<CFilterGraphListPropertySheet> 22 25 { 23 26 public: … … 35 38 class CListPropertyPage : 36 39 public CPropertyPageT<CListPropertyPage>, 37 public CDialogResize<CListPropertyPage> 40 public CDialogResize<CListPropertyPage>, 41 public CPropertyPageWithAcceleratorsT<CListPropertyPage> 38 42 { 39 43 public: … … 44 48 CHAIN_MSG_MAP(CPropertyPage) 45 49 CHAIN_MSG_MAP(CDialogResize<CListPropertyPage>) 50 CHAIN_MSG_MAP(CPropertyPageWithAccelerators) 46 51 MSG_WM_INITDIALOG(OnInitDialog) 47 52 MSG_WM_DESTROY(OnDestroy) … … 50 55 MSG_LVN_ITEMCHANGED(IDC_FILTERGRAPHLIST_LIST_GRAPH, OnGraphListViewItemChanged) 51 56 MSG_LVN_DBLCLK(IDC_FILTERGRAPHLIST_LIST_GRAPH, OnGraphListViewDblClk) 57 MSG_WM_CONTEXTMENU(OnContextMenu) 52 58 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_REFRESH, OnRefresh) 53 59 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_CHECK, OnCheck) 60 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_CHECKALL, OnCheckAll) 54 61 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_COPYTOCLIPBOARD, OnCopyToClipboard) 55 62 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_PROPERTIES, OnProperties) 63 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_OPENGSN, OnOpenGsn) 64 COMMAND_ID_HANDLER_EX(IDC_FILTERGRAPHLIST_LIST_OPENGE, OnOpenGe) 56 65 REFLECT_NOTIFICATIONS() 57 66 END_MSG_MAP() … … 81 90 CComPtr<IUnknown> m_pFilterGraphUnknown; 82 91 CComPtr<IFilterGraph> m_pFilterGraph; 92 CStringW m_sFriendlyName; 83 93 SIZE_T m_nFilterCount; 84 94 CString m_sState; … … 108 118 m_pFilterGraphUnknown = pUnknown; 109 119 m_pFilterGraph = pFilterGraph; 120 _ATLTRY 121 { 122 const CComQIPtr<ISpy> pSpy = pFilterGraph; 123 if(pSpy) 124 { 125 CComBSTR sFriendlyName; 126 __C(pSpy->get_FriendlyName(&sFriendlyName)); 127 m_sFriendlyName = sFriendlyName; 128 } 129 } 130 _ATLCATCHALL() 131 { 132 _Z_EXCEPTION(); 133 } 110 134 m_nFilterCount = 0; 111 135 m_sState.Empty(); … … 185 209 { 186 210 const UINT nSelectedCount = m_GraphListView.GetSelectedCount(); 211 m_CheckButton.EnableWindow(nSelectedCount > 0); 187 212 m_CopyToClipboardButton.EnableWindow(nSelectedCount > 0); 188 213 m_PropertiesButton.EnableWindow(nSelectedCount == 1); … … 369 394 return 0; 370 395 } 396 LRESULT OnTranslateAccelerator(MSG* pMessage) 397 { 398 return TranslateAccelerator(m_hWnd, m_hAccelerators, pMessage) ? PSNRET_MESSAGEHANDLED : PSNRET_NOERROR; 399 } 371 400 LRESULT OnGraphListViewGetDispInfo(NMLVDISPINFO* pHeader) 372 401 { … … 383 412 sTextBuffer = Item.m_sTime; 384 413 break; 385 case 3: // Filter Count 414 case 3: // Friendly Name 415 sTextBuffer = CString(Item.m_sFriendlyName); 416 break; 417 case 4: // Filter Count 386 418 if(Item.m_pFilterGraph) 387 419 sTextBuffer = AtlFormatString(_T("%d"), Item.m_nFilterCount); 388 420 break; 389 case 4: // State421 case 5: // State 390 422 if(Item.m_pFilterGraph) 391 423 sTextBuffer = Item.m_sState; 392 424 break; 393 case 5: // Process Image Directory425 case 6: // Process Image Directory 394 426 sTextBuffer = (LPCTSTR) GetPathDirectory(Item.m_sProcessImagePath); 395 427 break; … … 407 439 sTextBuffer.AppendFormat(_T("Process: %d (0x%X) %s\r\n"), Item.m_nProcessIdentifier, Item.m_nProcessIdentifier, CString(FindFileName(Item.m_sProcessImagePath))); 408 440 if(!Item.m_sTime.IsEmpty()) 409 sTextBuffer.AppendFormat(_T("CreationTime: %s\r\n"), Item.m_sTime); 441 sTextBuffer.AppendFormat(_T("Creation Time: %s\r\n"), Item.m_sTime); 442 if(!Item.m_sFriendlyName.IsEmpty()) 443 sTextBuffer.AppendFormat(_T("Friendly Name: %ls\r\n"), Item.m_sFriendlyName); 410 444 if(Item.m_pFilterGraph) 411 445 { … … 452 486 return 0; 453 487 } 488 LRESULT OnContextMenu(CWindow Window, CPoint Position) 489 { 490 if(Window == m_GraphListView) 491 { 492 CMenu ContainerMenu = AtlLoadMenu(IDD); 493 CMenuHandle Menu = ContainerMenu.GetSubMenu(0); 494 const UINT nCount = m_GraphListView.GetItemCount(); 495 const UINT nSelectedCount = m_GraphListView.GetSelectedCount(); 496 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_CHECK, MF_BYCOMMAND | (m_CheckButton.IsWindowEnabled() ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 497 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_CHECKALL, MF_BYCOMMAND | ((nCount > 0) ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 498 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_COPYTOCLIPBOARD, MF_BYCOMMAND | (m_CopyToClipboardButton.IsWindowEnabled() ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 499 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_OPENGSN, MF_BYCOMMAND | ((nSelectedCount == 1) ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 500 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_OPENGE, MF_BYCOMMAND | ((nSelectedCount == 1) ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 501 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_REFRESH, MF_BYCOMMAND | (m_RefreshButton.IsWindowEnabled() ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 502 Menu.EnableMenuItem(IDC_FILTERGRAPHLIST_LIST_PROPERTIES, MF_BYCOMMAND | (m_PropertiesButton.IsWindowEnabled() ? MF_ENABLED : MF_GRAYED | MF_DISABLED)); 503 Menu.SetMenuDefaultItem(IDC_FILTERGRAPHLIST_LIST_PROPERTIES); 504 Menu.TrackPopupMenu(TPM_RIGHTBUTTON | TPM_LEFTALIGN | TPM_TOPALIGN, Position.x, Position.y, m_hWnd); 505 } 506 return 0; 507 } 454 508 LRESULT OnRefresh(UINT, INT, HWND) 455 509 { … … 463 517 CWaitCursor WaitCursor; 464 518 for(INT nItem = m_GraphListView.GetNextItem(-1, LVNI_SELECTED); nItem >= 0; nItem = m_GraphListView.GetNextItem(nItem, LVNI_SELECTED)) 519 { 520 CItem& Item = m_GraphListView.GetItemData(nItem); 521 if(Item.FilterGraphNeeded(m_pRunningObjectTable)) 522 if(Item.Check()) 523 m_GraphListView.RedrawItems(nItem, nItem); 524 } 525 return 0; 526 } 527 LRESULT OnCheckAll(UINT, INT, HWND) 528 { 529 CWaitCursor WaitCursor; 530 for(INT nItem = m_GraphListView.GetItemCount() - 1; nItem >= 0; nItem--) 465 531 { 466 532 CItem& Item = m_GraphListView.GetItemData(nItem); … … 493 559 pFilterGraphHelper->SetFilterGraph(Item.m_pFilterGraph); 494 560 _V(pFilterGraphHelper->DoPropertyFrameModal((LONG) (LONG_PTR) m_hWnd)); 561 return 0; 562 } 563 LRESULT OnOpenGsn(UINT, INT, HWND) 564 { 565 const INT nItem = m_GraphListView.GetNextItem(-1, LVNI_SELECTED); 566 if(nItem < 0) 567 return 0; 568 CItem& Item = m_GraphListView.GetItemData(nItem); 569 if(!Item.FilterGraphNeeded(m_pRunningObjectTable)) 570 return 0; 571 CFilterGraphHelper::OpenMonikerWithGsn(Item.m_sDisplayName, m_hWnd); 572 return 0; 573 } 574 LRESULT OnOpenGe(UINT, INT, HWND) 575 { 576 const INT nItem = m_GraphListView.GetNextItem(-1, LVNI_SELECTED); 577 if(nItem < 0) 578 return 0; 579 CItem& Item = m_GraphListView.GetItemData(nItem); 580 if(!Item.FilterGraphNeeded(m_pRunningObjectTable)) 581 return 0; 582 CFilterGraphHelper::OpenMonikerWithGe(Item.m_sDisplayName, m_hWnd); 495 583 return 0; 496 584 } … … 532 620 return TRUE; 533 621 } 622 INT_PTR DoModal(HWND hParentWindow) 623 { 624 return CPropertySheetWithAccelerators::DoModal(hParentWindow); 625 } 534 626 535 627 // Window message handelrs … … 551 643 }; 552 644 645 inline INT_PTR DoFilterGraphListPropertySheetModal(HWND hParentWindow) 646 { 647 CFilterGraphListPropertySheet PropertySheet; 648 return PropertySheet.DoModal(hParentWindow); 649 } -
trunk/DirectShowSpy/FilterGraphSpy.h
r196 r242 85 85 T* m_pSpy; 86 86 87 CObjectPtr<T> GetSpy() const throw()87 CObjectPtr<T> GetSpy() const 88 88 { 89 89 CRoCriticalSectionLock DataLock(m_DataCriticalSection); … … 93 93 public: 94 94 // CAmGraphBuilderCallback 95 CAmGraphBuilderCallback() throw():95 CAmGraphBuilderCallback() : 96 96 m_pSpy(NULL) 97 97 { 98 98 _Z5(atlTraceRefcount, 5, _T("this 0x%p\n"), this); 99 99 } 100 ~CAmGraphBuilderCallback() throw()100 ~CAmGraphBuilderCallback() 101 101 { 102 102 _Z4(atlTraceRefcount, 4, _T("this 0x%p\n"), this); 103 103 } 104 VOID Initialize(T* pSpy) throw()104 VOID Initialize(T* pSpy) 105 105 { 106 106 _A(pSpy); … … 110 110 m_pSpy = pSpy; 111 111 } 112 VOID Terminate() throw()112 VOID Terminate() 113 113 { 114 114 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 115 115 m_pSpy = NULL; 116 116 } 117 BOOL SetGraphBuilder(const CComQIPtr<IObjectWithSite> pObjectWithSite) throw()117 BOOL SetGraphBuilder(const CComQIPtr<IObjectWithSite> pObjectWithSite) 118 118 { 119 119 if(!pObjectWithSite) … … 125 125 return FALSE; 126 126 } 127 BOOL SetGraphBuilder(IUnknown* pObjectWithSiteUnknown) throw()127 BOOL SetGraphBuilder(IUnknown* pObjectWithSiteUnknown) 128 128 { 129 129 return SetGraphBuilder(CComQIPtr<IObjectWithSite>(pObjectWithSiteUnknown)); … … 131 131 132 132 // IAMGraphBuilderCallback 133 STDMETHOD(SelectedFilter)(IMoniker* pMoniker) throw()133 STDMETHOD(SelectedFilter)(IMoniker* pMoniker) 134 134 { 135 135 _Z4(atlTraceCOM, 4, _T("this 0x%p, pMoniker %ls\n"), this, _FilterGraphHelper::GetMonikerDisplayName(pMoniker)); … … 152 152 return S_OK; 153 153 } 154 STDMETHOD(CreatedFilter)(IBaseFilter* pBaseFilter) throw()154 STDMETHOD(CreatedFilter)(IBaseFilter* pBaseFilter) 155 155 { 156 156 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilter 0x%p %ls \"%ls\"\n"), this, pBaseFilter, _FilterGraphHelper::GetFilterClassIdentifierString(pBaseFilter), _FilterGraphHelper::GetFilterName(pBaseFilter)); … … 186 186 _FilterGraphHelper::CRotRunningFilterGraph m_RunningFilterGraph; 187 187 INT m_nRunningFilterGraphReference; 188 SYSTEMTIME m_Time; 189 CStringW m_sMonikerDisplayName; 188 190 CComPtr<IUnknown> m_pTemporaryUnknown; 189 191 CObjectPtr<CAmGraphBuilderCallback> m_pPrivateAmGraphBuilderCallback; 190 192 mutable CRoCriticalSection m_DataCriticalSection; 191 193 CComPtr<IUnknown> m_pSite; 192 193 BOOL IsAggregated() const throw() 194 CStringW m_sFriendlyName; 195 196 BOOL IsAggregated() const 194 197 { 195 198 return (ULONG) m_dwRef >= 0x00001000; 196 199 } 197 VOID ReleaseTemporaryUnknown() throw()200 VOID ReleaseTemporaryUnknown() 198 201 { 199 202 CComPtr<IUnknown> pUnknown; … … 210 213 CInterlockedLong& nReferenceCount = reinterpret_cast<CInterlockedLong&>(m_dwRef); 211 214 const LONG nBeforeReferenceCount = m_dwRef; 215 SYSTEMTIME Time; 216 GetLocalTime(&Time); 217 CStringW sMonikerDisplayName; 212 218 static CConstIntegerRegistryValue g_nEnableRotMonikerItemNameSuffix(_T("Enable ROT Moniker Item Name Suffix")); // 0 Default (Enabled), 1 Disabled, 2 Enabled 213 219 if(g_nEnableRotMonikerItemNameSuffix != 1) … … 216 222 _W(GetModuleFileName(NULL, pszPath, DIM(pszPath))); 217 223 LPCTSTR pszName = FindFileName(pszPath); 218 SYSTEMTIME Time;219 GetLocalTime(&Time);220 224 CString sItemName = AtlFormatString(_T("%s; process: %s, time: %02d-%02d-%02d"), m_RunningFilterGraph.GetDefaultMonikerItemName(GetControllingUnknown()), pszName, Time.wHour, Time.wMinute, Time.wSecond); 221 m_RunningFilterGraph.SetFilterGraph(GetControllingUnknown(), CStringW(sItemName) );225 m_RunningFilterGraph.SetFilterGraph(GetControllingUnknown(), CStringW(sItemName), &sMonikerDisplayName); 222 226 } else 223 m_RunningFilterGraph.SetFilterGraph(GetControllingUnknown()); 224 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_bIsAggregated %d, m_dwRef %d\n"), this, m_bIsAggregated, m_dwRef); 227 m_RunningFilterGraph.SetFilterGraph(GetControllingUnknown(), &sMonikerDisplayName); 228 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_bIsAggregated %d, m_dwRef %d, sMonikerDisplayName \"%ls\"\n"), this, m_bIsAggregated, m_dwRef, sMonikerDisplayName); 229 { 230 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 231 m_Time = Time; 232 m_sMonikerDisplayName = sMonikerDisplayName; 233 } 225 234 if(!m_bIsAggregated) 226 235 { … … 236 245 Release(); 237 246 } 238 VOID ResetRunningFilterGraph() throw()247 VOID ResetRunningFilterGraph() 239 248 { 240 249 if(!m_RunningFilterGraph.GetCookie()) … … 244 253 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x%x\n"), this, m_dwRef); 245 254 m_RunningFilterGraph.SetFilterGraph(NULL); 255 { 256 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 257 m_sMonikerDisplayName.Empty(); 258 } 246 259 _Z4(atlTraceRefcount, 4, _T("this 0x%p, m_dwRef 0x%x\n"), this, m_dwRef); 247 260 } 248 HRESULT InternalQueryFilterGraph3Interface(REFIID InterfaceIdentifier, VOID** ppvObject) throw()261 HRESULT InternalQueryFilterGraph3Interface(REFIID InterfaceIdentifier, VOID** ppvObject) 249 262 { 250 263 _A(InterfaceIdentifier == __uuidof(IFilterGraph3)); … … 260 273 return S_OK; 261 274 } 262 static HRESULT WINAPI QueryFilterGraph3Interface(VOID* pvThis, REFIID InterfaceIdentifier, VOID** ppvObject, DWORD_PTR) throw()275 static HRESULT WINAPI QueryFilterGraph3Interface(VOID* pvThis, REFIID InterfaceIdentifier, VOID** ppvObject, DWORD_PTR) 263 276 { 264 277 return ((CSpy*) pvThis)->InternalQueryFilterGraph3Interface(InterfaceIdentifier, ppvObject); 265 278 } 266 HRESULT HookMediaControlAddSourceFilter(BSTR sFileName, IBaseFilter** ppBaseFilter, BOOL* pbDefault) throw()279 HRESULT HookMediaControlAddSourceFilter(BSTR sFileName, IBaseFilter** ppBaseFilter, BOOL* pbDefault) 267 280 { 268 281 _A(pbDefault); … … 276 289 public: 277 290 // CSpyT 278 static LPCTSTR GetOriginalLibraryName() throw()291 static LPCTSTR GetOriginalLibraryName() 279 292 { 280 293 return _T("quartz.dll"); … … 284 297 return _StringHelper::GetLine(T::IDR, 2); 285 298 } 286 static HRESULT WINAPI UpdateRegistry(BOOL bRegister) throw()299 static HRESULT WINAPI UpdateRegistry(BOOL bRegister) 287 300 { 288 301 _Z2(atlTraceRegistrar, 2, _T("bRegister %d\n"), bRegister); … … 297 310 return S_OK; 298 311 } 299 CSpyT() throw():312 CSpyT() : 300 313 m_hQuartzModule(NULL) 301 314 { 302 315 _Z4(atlTraceRefcount, 4, _T("this 0x%p\n"), this); 303 } 304 ~CSpyT() throw() 316 ZeroMemory(&m_Time, sizeof m_Time); 317 } 318 ~CSpyT() 305 319 { 306 320 _Z4(atlTraceRefcount, 4, _T("this 0x%p\n"), this); 307 321 } 308 HRESULT FinalConstruct() throw()322 HRESULT FinalConstruct() 309 323 { 310 324 m_bIsAggregated = IsAggregated(); … … 419 433 return S_OK; 420 434 } 421 VOID FinalRelease() throw()435 VOID FinalRelease() 422 436 { 423 437 _Z5(atlTraceRefcount, 5, _T("m_dwRef 0x%x\n"), m_dwRef); … … 479 493 #pragma endregion 480 494 } 481 HRESULT QueryObjectWithSiteInterface(REFIID InterfaceIdentifier, LPVOID* ppvObject) throw()495 HRESULT QueryObjectWithSiteInterface(REFIID InterfaceIdentifier, LPVOID* ppvObject) 482 496 { 483 497 _A(InterfaceIdentifier == __uuidof(IObjectWithSite)); … … 491 505 return m_pInnerUnknown->QueryInterface(InterfaceIdentifier, ppvObject); 492 506 } 493 static HRESULT WINAPI QueryObjectWithSiteInterface(VOID* pvInstance, REFIID InterfaceIdentifier, LPVOID* ppvObject, DWORD_PTR) throw()507 static HRESULT WINAPI QueryObjectWithSiteInterface(VOID* pvInstance, REFIID InterfaceIdentifier, LPVOID* ppvObject, DWORD_PTR) 494 508 { 495 509 return ((CSpy*) pvInstance)->QueryObjectWithSiteInterface(InterfaceIdentifier, ppvObject); 496 510 } 497 CComPtr<IUnknown> GetSite() const throw()511 CComPtr<IUnknown> GetSite() const 498 512 { 499 513 CRoCriticalSectionLock DataLock(m_DataCriticalSection); … … 520 534 return FALSE; 521 535 } 522 static BOOL LookupEventCodeName(LONG nEventCode, LPCSTR& pszName) throw()536 static BOOL LookupEventCodeName(LONG nEventCode, LPCSTR& pszName) 523 537 { 524 538 // NOTE: See Windows SDK evcode.h … … 573 587 574 588 // ISpy 589 STDMETHOD(get_MonikerDisplayName)(BSTR* psMonikerDisplayName) 590 { 591 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 592 _ATLTRY 593 { 594 __D(psMonikerDisplayName, E_POINTER); 595 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 596 *psMonikerDisplayName = CComBSTR(m_sMonikerDisplayName).Detach(); 597 } 598 _ATLCATCHALL() 599 { 600 _Z_EXCEPTION(); 601 } 602 return S_OK; 603 } 604 STDMETHOD(get_CreationTime)(DATE* pfTime) 605 { 606 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 607 _ATLTRY 608 { 609 __D(pfTime, E_POINTER); 610 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 611 FILETIME LocalFileTime, FileTime; 612 _W(SystemTimeToFileTime(&m_Time, &LocalFileTime)); 613 _W(LocalFileTimeToFileTime(&LocalFileTime, &FileTime)); 614 SYSTEMTIME Time; 615 _W(FileTimeToSystemTime(&FileTime, &Time)); 616 _W(SystemTimeToVariantTime(&Time, pfTime)); 617 } 618 _ATLCATCHALL() 619 { 620 _Z_EXCEPTION(); 621 } 622 return S_OK; 623 } 624 STDMETHOD(get_FriendlyName)(BSTR* psFriendlyName) 625 { 626 _Z4(atlTraceCOM, 4, _T("this 0x%p\n"), this); 627 _ATLTRY 628 { 629 __D(psFriendlyName, E_POINTER); 630 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 631 *psFriendlyName = CComBSTR(m_sFriendlyName).Detach(); 632 } 633 _ATLCATCHALL() 634 { 635 _Z_EXCEPTION(); 636 } 637 return S_OK; 638 } 639 STDMETHOD(put_FriendlyName)(BSTR sFriendlyName) 640 { 641 _Z4(atlTraceCOM, 4, _T("this 0x%p, sFriendlyName \"%s\"\n"), this, CString(sFriendlyName)); 642 _ATLTRY 643 { 644 CRoCriticalSectionLock DataLock(m_DataCriticalSection); 645 m_sFriendlyName = sFriendlyName; 646 } 647 _ATLCATCHALL() 648 { 649 _Z_EXCEPTION(); 650 } 651 return S_OK; 652 } 575 653 576 654 // IFilterGraph 577 STDMETHOD(AddFilter)(IBaseFilter* pBaseFilter, LPCWSTR pszName) throw()655 STDMETHOD(AddFilter)(IBaseFilter* pBaseFilter, LPCWSTR pszName) 578 656 { 579 657 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilter 0x%p %ls, pszName \"%s\"\n"), this, pBaseFilter, _FilterGraphHelper::GetFilterClassIdentifierString(pBaseFilter), CString(pszName)); … … 595 673 return nResult; 596 674 } 597 STDMETHOD(RemoveFilter)(IBaseFilter* pBaseFilter) throw()675 STDMETHOD(RemoveFilter)(IBaseFilter* pBaseFilter) 598 676 { 599 677 _Z4(atlTraceCOM, 4, _T("this 0x%p, pBaseFilter 0x%p\n"), this, pBaseFilter); … … 613 691 return m_pInnerFilterGraph2->RemoveFilter(pBaseFilter); 614 692 } 615 STDMETHOD(EnumFilters)(IEnumFilters** ppEnumFilters) throw()693 STDMETHOD(EnumFilters)(IEnumFilters** ppEnumFilters) 616 694 { 617 695 _Z4(atlTraceCOM, 4, _T("...\n")); 618 696 return m_pInnerFilterGraph2->EnumFilters(ppEnumFilters); 619 697 } 620 STDMETHOD(FindFilterByName)(LPCWSTR pszName, IBaseFilter** ppFilter) throw()698 STDMETHOD(FindFilterByName)(LPCWSTR pszName, IBaseFilter** ppFilter) 621 699 { 622 700 _Z4(atlTraceCOM, 4, _T("pszName \"%s\"\n"), CString(pszName)); 623 701 return m_pInnerFilterGraph2->FindFilterByName(pszName, ppFilter); 624 702 } 625 STDMETHOD(ConnectDirect)(IPin* pOutputPin, IPin* pInputPin, const AM_MEDIA_TYPE* pMediaType) throw()703 STDMETHOD(ConnectDirect)(IPin* pOutputPin, IPin* pInputPin, const AM_MEDIA_TYPE* pMediaType) 626 704 { 627 705 _Z4(atlTraceCOM, 4, _T("...\n")); … … 642 720 return m_pInnerFilterGraph2->ConnectDirect(pOutputPin, pInputPin, pMediaType); 643 721 } 644 STDMETHOD(Reconnect)(IPin* pPin) throw()722 STDMETHOD(Reconnect)(IPin* pPin) 645 723 { 646 724 _Z4(atlTraceCOM, 4, _T("...\n")); … … 650 728 return m_pInnerFilterGraph2->Reconnect(pPin); 651 729 } 652 STDMETHOD(Disconnect)(IPin* pPin) throw()730 STDMETHOD(Disconnect)(IPin* pPin) 653 731 { 654 732 _Z4(atlTraceCOM, 4, _T("...\n")); … … 658 736 return m_pInnerFilterGraph2->Disconnect(pPin); 659 737 } 660 STDMETHOD(SetDefaultSyncSource)() throw()738 STDMETHOD(SetDefaultSyncSource)() 661 739 { 662 740 _Z4(atlTraceCOM, 4, _T("...\n")); … … 665 743 666 744 // IGraphBuilder 667 STDMETHOD(Connect)(IPin* pOutputPin, IPin* pInputPin) throw()745 STDMETHOD(Connect)(IPin* pOutputPin, IPin* pInputPin) 668 746 { 669 747 _Z4(atlTraceCOM, 4, _T("pOutputPin 0x%p, pInputPin 0x%p\n"), pOutputPin, pInputPin); … … 685 763 return m_pInnerFilterGraph2->Connect(pOutputPin, pInputPin); 686 764 } 687 STDMETHOD(Render)(IPin* pOutputPin) throw()765 STDMETHOD(Render)(IPin* pOutputPin) 688 766 { 689 767 _Z4(atlTraceCOM, 4, _T("...\n")); 690 768 return m_pInnerFilterGraph2->Render(pOutputPin); 691 769 } 692 STDMETHOD(RenderFile)(LPCWSTR pszFileName, LPCWSTR pszPlayListFileName) throw()770 STDMETHOD(RenderFile)(LPCWSTR pszFileName, LPCWSTR pszPlayListFileName) 693 771 { 694 772 _Z4(atlTraceCOM, 4, _T("pszFileName \"%s\", pszPlayListFileName \"%s\"\n"), CString(pszFileName), CString(pszPlayListFileName)); 695 773 return m_pInnerFilterGraph2->RenderFile(pszFileName, pszPlayListFileName); 696 774 } 697 STDMETHOD(AddSourceFilter)(LPCWSTR pszFileName, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) throw()775 STDMETHOD(AddSourceFilter)(LPCWSTR pszFileName, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) 698 776 { 699 777 _Z4(atlTraceCOM, 4, _T("pszFileName \"%s\", pszFilterName \"%s\"\n"), CString(pszFileName), CString(pszFilterName)); … … 704 782 return m_pInnerFilterGraph2->AddSourceFilter(pszFileName, pszFilterName, ppBaseFilter); 705 783 } 706 STDMETHOD(SetLogFile)(DWORD_PTR hFile) throw()784 STDMETHOD(SetLogFile)(DWORD_PTR hFile) 707 785 { 708 786 _Z4(atlTraceCOM, 4, _T("...\n")); 709 787 return m_pInnerFilterGraph2->SetLogFile(hFile); 710 788 } 711 STDMETHOD(Abort)() throw()789 STDMETHOD(Abort)() 712 790 { 713 791 _Z4(atlTraceCOM, 4, _T("...\n")); 714 792 return m_pInnerFilterGraph2->Abort(); 715 793 } 716 STDMETHOD(ShouldOperationContinue)() throw()794 STDMETHOD(ShouldOperationContinue)() 717 795 { 718 796 _Z4(atlTraceCOM, 4, _T("...\n")); … … 721 799 722 800 // IFilterGraph2 723 STDMETHOD(AddSourceFilterForMoniker)(IMoniker* pMoniker, IBindCtx* pBindCtx, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) throw()801 STDMETHOD(AddSourceFilterForMoniker)(IMoniker* pMoniker, IBindCtx* pBindCtx, LPCWSTR pszFilterName, IBaseFilter** ppBaseFilter) 724 802 { 725 803 _Z4(atlTraceCOM, 4, _T("pszFilterName \"%s\"\n"), CString(pszFilterName)); … … 730 808 return m_pInnerFilterGraph2->AddSourceFilterForMoniker(pMoniker, pBindCtx, pszFilterName, ppBaseFilter); 731 809 } 732 STDMETHOD(ReconnectEx)(IPin* pPin, const AM_MEDIA_TYPE* pMediaType) throw()810 STDMETHOD(ReconnectEx)(IPin* pPin, const AM_MEDIA_TYPE* pMediaType) 733 811 { 734 812 _Z4(atlTraceCOM, 4, _T("...\n")); … … 738 816 return m_pInnerFilterGraph2->ReconnectEx(pPin, pMediaType); 739 817 } 740 STDMETHOD(RenderEx)(IPin* pOutputPin, DWORD nFlags, DWORD* pnContext) throw()818 STDMETHOD(RenderEx)(IPin* pOutputPin, DWORD nFlags, DWORD* pnContext) 741 819 { 742 820 _Z4(atlTraceCOM, 4, _T("nFlags 0x%x\n"), nFlags); … … 745 823 746 824 // IFilterGraph3 747 STDMETHOD(SetSyncSourceEx)(IReferenceClock* pFilterGraphReferenceClock, IReferenceClock* pFilterReferenceClock, IBaseFilter* pBaseFilter) throw()825 STDMETHOD(SetSyncSourceEx)(IReferenceClock* pFilterGraphReferenceClock, IReferenceClock* pFilterReferenceClock, IBaseFilter* pBaseFilter) 748 826 { 749 827 _Z4(atlTraceCOM, 4, _T("...\n")); … … 753 831 754 832 // IMediaControl 755 STDMETHOD(Run)() throw()833 STDMETHOD(Run)() 756 834 { 757 835 _Z4(atlTraceCOM, 4, _T("...\n")); … … 773 851 return nRunResult; 774 852 } 775 STDMETHOD(Pause)() throw()853 STDMETHOD(Pause)() 776 854 { 777 855 _Z4(atlTraceCOM, 4, _T("...\n")); … … 791 869 return m_pInnerMediaControl->Pause(); 792 870 } 793 STDMETHOD(Stop)() throw()871 STDMETHOD(Stop)() 794 872 { 795 873 _Z4(atlTraceCOM, 4, _T("...\n")); … … 799 877 return m_pInnerMediaControl->Stop(); 800 878 } 801 STDMETHOD(GetState)(LONG nTimeout, OAFilterState* pState) throw()879 STDMETHOD(GetState)(LONG nTimeout, OAFilterState* pState) 802 880 { 803 881 _Z5(atlTraceCOM, 5, _T("nTimeout %d\n"), nTimeout); 804 882 return m_pInnerMediaControl->GetState(nTimeout, pState); 805 883 } 806 STDMETHOD(RenderFile)(BSTR sFileName) throw()884 STDMETHOD(RenderFile)(BSTR sFileName) 807 885 { 808 886 _Z4(atlTraceCOM, 4, _T("sFileName \"%s\"\n"), CString(sFileName)); 809 887 return m_pInnerMediaControl->RenderFile(sFileName); 810 888 } 811 STDMETHOD(AddSourceFilter)(BSTR sFileName, IDispatch** ppDispatch) throw()889 STDMETHOD(AddSourceFilter)(BSTR sFileName, IDispatch** ppDispatch) 812 890 { 813 891 _Z4(atlTraceCOM, 4, _T("sFileName \"%s\"\n"), CString(sFileName)); … … 837 915 return m_pInnerMediaControl->AddSourceFilter(sFileName, ppDispatch); 838 916 } 839 STDMETHOD(get_FilterCollection)(IDispatch** ppDispatch) throw()917 STDMETHOD(get_FilterCollection)(IDispatch** ppDispatch) 840 918 { 841 919 _Z4(atlTraceCOM, 4, _T("...\n")); … … 843 921 return m_pInnerMediaControl->get_FilterCollection(ppDispatch); 844 922 } 845 STDMETHOD(get_RegFilterCollection)(IDispatch** ppDispatch) throw()923 STDMETHOD(get_RegFilterCollection)(IDispatch** ppDispatch) 846 924 { 847 925 _Z4(atlTraceCOM, 4, _T("...\n")); … … 849 927 return m_pInnerMediaControl->get_RegFilterCollection(ppDispatch); 850 928 } 851 STDMETHOD(StopWhenReady)() throw()929 STDMETHOD(StopWhenReady)() 852 930 { 853 931 _Z4(atlTraceCOM, 4, _T("...\n")); … … 856 934 857 935 // IMediaEventSink 858 STDMETHOD(Notify)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) throw()936 STDMETHOD(Notify)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) 859 937 { 860 938 #if TRUE … … 881 959 882 960 // IMediaEvent 883 STDMETHOD(GetEventHandle)(OAEVENT* pnEventHandle) throw()961 STDMETHOD(GetEventHandle)(OAEVENT* pnEventHandle) 884 962 { 885 963 _Z4(atlTraceCOM, 4, _T("...\n")); 886 964 return m_pInnerMediaEventEx->GetEventHandle(pnEventHandle); 887 965 } 888 STDMETHOD(GetEvent)(LONG* pnEventCode, LONG_PTR* pnParameter1, LONG_PTR* pnParameter2, LONG nTimeout) throw()966 STDMETHOD(GetEvent)(LONG* pnEventCode, LONG_PTR* pnParameter1, LONG_PTR* pnParameter2, LONG nTimeout) 889 967 { 890 968 _Z4(atlTraceCOM, nTimeout ? 4 : 5, _T("nTimeout %d\n"), nTimeout); … … 894 972 return nGetEventResult; 895 973 } 896 STDMETHOD(WaitForCompletion)(LONG nTimeout, LONG* pnEventCode) throw()974 STDMETHOD(WaitForCompletion)(LONG nTimeout, LONG* pnEventCode) 897 975 { 898 976 _Z4(atlTraceCOM, 4, _T("nTimeout %d\n"), nTimeout); … … 902 980 return nWaitForCompletionResult; 903 981 } 904 STDMETHOD(CancelDefaultHandling)(LONG nEventCode) throw()982 STDMETHOD(CancelDefaultHandling)(LONG nEventCode) 905 983 { 906 984 #if TRUE … … 914 992 return m_pInnerMediaEventEx->CancelDefaultHandling(nEventCode); 915 993 } 916 STDMETHOD(RestoreDefaultHandling)(LONG nEventCode) throw()994 STDMETHOD(RestoreDefaultHandling)(LONG nEventCode) 917 995 { 918 996 #if TRUE … … 926 1004 return m_pInnerMediaEventEx->RestoreDefaultHandling(nEventCode); 927 1005 } 928 STDMETHOD(FreeEventParams)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) throw()1006 STDMETHOD(FreeEventParams)(LONG nEventCode, LONG_PTR nParameter1, LONG_PTR nParameter2) 929 1007 { 930 1008 _Z4(atlTraceCOM, 4, _T("nEventCode 0x%02X, nParameter1 0x%p, nParameter2 0x%p\n"), nEventCode, nParameter1, nParameter2); … … 933 1011 934 1012 // IMediaEventEx 935 STDMETHOD(SetNotifyWindow)(OAHWND nWindowHandle, LONG nMessage, LONG_PTR nParameter) throw()1013 STDMETHOD(SetNotifyWindow)(OAHWND nWindowHandle, LONG nMessage, LONG_PTR nParameter) 936 1014 { 937 1015 _Z4(atlTraceCOM, 4, _T("nWindowHandle 0x%08x, nMessage 0x%04x, nParameter %p\n"), nWindowHandle, nMessage, nParameter); 938 1016 return m_pInnerMediaEventEx->SetNotifyWindow(nWindowHandle, nMessage, nParameter); 939 1017 } 940 STDMETHOD(SetNotifyFlags)(LONG nNotifyFlags) throw()1018 STDMETHOD(SetNotifyFlags)(LONG nNotifyFlags) 941 1019 { 942 1020 _Z4(atlTraceCOM, 4, _T("nNotifyFlags 0x%x\n"), nNotifyFlags); 943 1021 return m_pInnerMediaEventEx->SetNotifyFlags(nNotifyFlags); 944 1022 } 945 STDMETHOD(GetNotifyFlags)(LONG* pnNotifyFlags) throw()1023 STDMETHOD(GetNotifyFlags)(LONG* pnNotifyFlags) 946 1024 { 947 1025 _Z4(atlTraceCOM, 4, _T("...\n")); … … 950 1028 951 1029 // IObjectWithSite 952 STDMETHOD(SetSite)(IUnknown* pSite) throw()1030 STDMETHOD(SetSite)(IUnknown* pSite) 953 1031 { 954 1032 _Z4(atlTraceCOM, 4, _T("pSite 0x%p\n"), pSite); … … 964 1042 return S_OK; 965 1043 } 966 STDMETHOD(GetSite)(REFIID InterfaceIdentifier, VOID** ppvSite) throw()1044 STDMETHOD(GetSite)(REFIID InterfaceIdentifier, VOID** ppvSite) 967 1045 { 968 1046 _Z4(atlTraceCOM, 4, _T("InterfaceIdentifier %ls\n"), _PersistHelper::StringFromInterfaceIdentifier(InterfaceIdentifier)); -
trunk/DirectShowSpy/GraphBuilderCallbackPropertySheet.h
r231 r242 1375 1375 } 1376 1376 }; 1377 -
trunk/DirectShowSpy/Helper.cpp
r231 r242 29 29 FilterGraph.CoCreateInstance(); 30 30 __C(FilterGraph.m_pFilterGraph->RenderFile(_T("E:\\Media\\Robotica_1080.wmv"), NULL)); 31 _ATLTRY 32 { 33 const CComQIPtr<ISpy> pSpy = FilterGraph.m_pFilterGraph; 34 if(pSpy) 35 __C(pSpy->put_FriendlyName(CComBSTR(_T("Test")))); 36 } 37 _ATLCATCHALL() 38 { 39 _Z_EXCEPTION(); 40 } 31 41 CLocalObjectPtr<CFilterGraphHelper> pHelper; 32 42 pHelper->SetFilterGraph(FilterGraph.m_pFilterGraph); -
trunk/DirectShowSpy/resource.h
r233 r242 11 11 #define IDI_LISTVIEW_FAILURE 81 12 12 #define IDS_PROJNAME 100 13 #define IDC_MAIN_EMAIL_METHOD 10114 #define IDR_FILTERGRAPHSPY 20015 #define IDR_NOTHREADFILTERGRAPHSPY 20116 #define IDR_FILTERMAPPERSPY 20217 #define IDR_SYSTEMDEVICEENUMERATORSPY 20318 #define IDR_FILTERGRAPHHELPER 25019 13 #define IDS_REGISTRATION_PROPERTYSHEETCAPTION 900 20 14 #define IDD_REGISTRATION_REGISTRATION_PROPERTYPAGE 910 … … 65 59 #define IDC_FILTERGRAPHLIST_LIST_REFRESH 1410 66 60 #define IDC_FILTERGRAPHLIST_LIST_CHECK 1411 67 #define IDC_FILTERGRAPHLIST_LIST_COPYTOCLIPBOARD 1412 68 #define IDC_FILTERGRAPHLIST_LIST_PROPERTIES 1413 61 #define IDC_FILTERGRAPHLIST_LIST_CHECKALL 1412 62 #define IDC_FILTERGRAPHLIST_LIST_COPYTOCLIPBOARD 1413 63 #define IDC_FILTERGRAPHLIST_LIST_PROPERTIES 1414 64 #define IDC_FILTERGRAPHLIST_LIST_OPENGSN 1420 65 #define IDC_FILTERGRAPHLIST_LIST_OPENGE 1421 69 66 #define IDD_FILTERGRAPHHELPER_PROPERTYFRAME 1500 70 67 #define IDC_FILTERGRAPHHELPER_PROPERTYFRAME_TREE 1505 … … 81 78 #define IDC_FILTERGRAPHHELPER_EMAIL_BODY 1608 82 79 #define IDC_FILTERGRAPHHELPER_EMAIL_SEND 1609 80 #define IDD_FILTERGRAPHHELPER_ACTION 1700 81 #define IDC_FILTERGRAPHHELPER_ACTION_TITLE 1701 82 #define IDC_FILTERGRAPHHELPER_ACTION_SAVEAS 1705 83 #define IDC_FILTERGRAPHHELPER_ACTION_SAVEASDESCRIPTION 1706 84 #define IDC_FILTERGRAPHHELPER_ACTION_OPENGSN 1707 85 #define IDC_FILTERGRAPHHELPER_ACTION_OPENGSNDESCRIPTION 1708 86 #define IDC_FILTERGRAPHHELPER_ACTION_OPENGE 1709 87 #define IDC_FILTERGRAPHHELPER_ACTION_OPENGEDESCRIPTION 1710 88 #define IDC_FILTERGRAPHHELPER_ACTION_OPENLIST 1711 89 #define IDC_FILTERGRAPHHELPER_ACTION_OPENLISTDESCRIPTION 1712 90 #define IDR_FILTERGRAPHSPY 25000 91 #define IDR_NOTHREADFILTERGRAPHSPY 25001 92 #define IDR_FILTERMAPPERSPY 25002 93 #define IDR_SYSTEMDEVICEENUMERATORSPY 25003 94 #define IDR_FILTERGRAPHHELPER 25050 83 95 #define IDD_ABOUT 29900 84 96 #define IDC_ABOUT_ICON 29901 … … 97 109 #ifdef APSTUDIO_INVOKED 98 110 #ifndef APSTUDIO_READONLY_SYMBOLS 99 #define _APS_NEXT_RESOURCE_VALUE 2 09100 #define _APS_NEXT_COMMAND_VALUE 327 68101 #define _APS_NEXT_CONTROL_VALUE 22 1111 #define _APS_NEXT_RESOURCE_VALUE 211 112 #define _APS_NEXT_COMMAND_VALUE 32781 113 #define _APS_NEXT_CONTROL_VALUE 228 102 114 #define _APS_NEXT_SYMED_VALUE 103 103 115 #endif
Note: See TracChangeset
for help on using the changeset viewer.