So, this function basically does... uhh.... I have no idea. :-D<div>What exactly does it do again? <br><br><div class="gmail_quote">On Wed, May 16, 2012 at 7:44 AM, Mehrdad <span dir="ltr"><<a href="mailto:wfunction@hotmail.com" target="_blank">wfunction@hotmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On Tuesday, 15 May 2012 at 14:03:47 UTC, Gor Gyolchanyan wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Can anyone, please, tell me what these manifests are, where do they fit in my application binaries, why is one needed to get the pretty windows 7 buttons and how to use them with DMD?<br>
</blockquote>
<br></div>
Just FYI, you don't actually *need* to include manifests in your executable, if you know another DLL already has them.<br>
<br>
Here's a hack to show what I mean, for enabling visual styles:<br>
<br>
void enableVisualStyles()<br>
{<br>
TCHAR[MAX_PATH] dir;<br>
dir[GetSystemDirectory(dir.<u></u>ptr, dir.length)] = '\0';<br>
enum<br>
{<br>
ACTCTX_FLAG_ASSEMBLY_<u></u>DIRECTORY_VALID = 0x00000004,<br>
ACTCTX_FLAG_RESOURCE_NAME_<u></u>VALID = 0x00000008,<br>
ACTCTX_FLAG_SET_PROCESS_<u></u>DEFAULT = 0x00000010,<br>
}<br>
auto actCtx = ACTCTX(ACTCTX.sizeof,<br>
ACTCTX_FLAG_RESOURCE_NAME_<u></u>VALID |<br>
ACTCTX_FLAG_SET_PROCESS_<u></u>DEFAULT |<br>
ACTCTX_FLAG_ASSEMBLY_<u></u>DIRECTORY_VALID,<br>
"shell32.dll", PROCESSOR_ARCHITECTURE_INTEL,<br>
0, dir.ptr, MAKEINTRESOURCE(124), null, null);<br>
auto hActCtx = CreateActCtx(actCtx);<br>
assert(hActCtx != INVALID_HANDLE_VALUE);<br>
ULONG_PTR ulpActivationCookie;<br>
BOOL success = ActivateActCtx(hActCtx, ulpActivationCookie);<br>
assert(success);<br>
}<br>
<br>
Basically, since shell32.dll already has our manifest, I can just call this function instead. :-)<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Bye,<br>Gor Gyolchanyan.<br>
</div>