* Tools/win32pbs.m: (+ownerByOsPb:) compare against name

instead of pasteboard object to prevent condition where
	paste works only once as observed on Windows.
	(MainWindowProc) Add code to handle WM_RENDERALLFORMATS as documented
	on MSDN here: http://msdn.microsoft.com/en-us/library/windows/desktop/ms649029(v=vs.85).aspx



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@35933 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
gcasa 2013-01-05 06:02:33 +00:00
parent a00f4f08e8
commit ed217caac9
2 changed files with 30 additions and 6 deletions

View file

@ -1,3 +1,12 @@
2013-01-05 00:54-EST Gregory John Casamento <greg.casamento@gmail.com>
Merging changes made by Marcian Lytwyn
* Tools/win32pbs.m: (+ownerByOsPb:) compare against name
instead of pasteboard object to prevent condition where
paste works only once as observed on Windows.
(MainWindowProc) Add code to handle WM_RENDERALLFORMATS as documented
on MSDN here: http://msdn.microsoft.com/en-us/library/windows/desktop/ms649029(v=vs.85).aspx
2012-12-31 Fred Kiefer <FredKiefer@gmx.de>
* Source/cairo/CairoFntInfo.m (-drawGlyphs:..., -setupAttributes):

View file

@ -77,7 +77,7 @@ LRESULT CALLBACK MainWndProc(HWND hwnd, UINT uMsg,
+ (id) ownerByOsPb: (NSString*)p
{
if ([p isEqual: [NSPasteboard generalPasteboard]])
if ([p isEqual: [[NSPasteboard generalPasteboard] name]])
{
return wpb;
}
@ -398,7 +398,22 @@ LRESULT CALLBACK MainWndProc(HWND hwnd, UINT uMsg,
break;
case WM_RENDERALLFORMATS:
[wpb setClipboardData];
if (!OpenClipboard(hwnd))
{
NSWarnMLog(@"Failed to get the Win32 clipboard. %d", GetLastError());
}
else if (GetClipboardOwner() == hwnd)
{
if (!EmptyClipboard())
{
NSWarnMLog(@"Failed to get the Win32 clipboard. %d", GetLastError());
}
else
{
SendMessage(hwnd, WM_RENDERFORMAT, CF_UNICODETEXT, 0);
CloseClipboard();
}
}
break;
default: