Mercurial > projects > dynamin
comparison dynamin/gui/windows_cursor.d @ 106:acdbb30fee7e
Port to D2.
Most of the effort was dealing with immutable and const.
author | Jordan Miner <jminer7@gmail.com> |
---|---|
date | Mon, 17 Dec 2012 23:41:50 -0600 |
parents | 73060bc3f004 |
children |
comparison
equal
deleted
inserted
replaced
105:97997a544ac0 | 106:acdbb30fee7e |
---|---|
30 IMAGE_CURSOR, 0, 0, LR_SHARED | LR_DEFAULTSIZE); | 30 IMAGE_CURSOR, 0, 0, LR_SHARED | LR_DEFAULTSIZE); |
31 if(hcur is null) | 31 if(hcur is null) |
32 Stdout.format("LoadImage() failed loading cursor {}", curRes).newline; | 32 Stdout.format("LoadImage() failed loading cursor {}", curRes).newline; |
33 return new Cursor(hcur); | 33 return new Cursor(hcur); |
34 } | 34 } |
35 Cursor backend_getCursor(wchar[] name) { | 35 Cursor backend_getCursor(const(wchar)[] name) { |
36 HCURSOR hcur = LoadImage(GetModuleHandle(null), name.ptr, | 36 HCURSOR hcur = LoadImage(GetModuleHandle(null), name.ptr, |
37 IMAGE_CURSOR, 0, 0, LR_DEFAULTSIZE); | 37 IMAGE_CURSOR, 0, 0, LR_DEFAULTSIZE); |
38 if(hcur is null) | 38 if(hcur is null) |
39 Stdout.format("LoadImage() failed loading cursor {}", name).newline; | 39 Stdout.format("LoadImage() failed loading cursor {}", name).newline; |
40 return new Cursor(hcur); | 40 return new Cursor(hcur); |