aboutsummaryrefslogtreecommitdiff
path: root/cocoa.m
AgeCommit message (Collapse)AuthorFilesLines
2010-01-07Cocoa: Use optimized drawing for the windowAndreas Färber1-0/+1
Default is NO. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Suppress window resize animationAndreas Färber1-1/+1
Disable the nice resize animation, to avoid drawing glitches following a guest's screen size change. Based on patch by Juha Riihimäki. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: Juha Riihimäki <juha.riihimaki@nokia.com> Cc: Alexander Graf <alex@csgraf.de> Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Shutdown when window is closedAndreas Färber1-0/+5
The application is not very useful once the guest window is closed. QEMU is not a document-based application; terminating it automatically saves the user another action and resembles SDL behavior. v2: - Use delegate method, suggested by Juha Riihimäki. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: Juha Riihimäki <juha.riihimaki@nokia.com> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Don't unconditionally show the windowAndreas Färber1-0/+10
When QEMU was launched in no-graphic, Curses or VNC mode, don't run it as a Cocoa application. Based on patch by Alexander Graf. v1: - Avoid type mismatch warning for argv - Drop noCocoa variable - Coding Style changes Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: Alexander Graf <agraf@suse.de> Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Redraw the View asynchronouslyAndreas Färber1-1/+1
Cf. http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CocoaPerformance/Articles/CustomViews.html Based on patch by Juha Riihimäki. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: Juha Riihimäki <juha.riihimaki@nokia.com> Cc: Alexander Graf <alex@csgraf.de> Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Mark the View as opaqueAndreas Färber1-0/+5
Default is NO. Cf. http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/CocoaPerformance/Articles/CustomViews.html Based on patch by Juha Riihimäki. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: Juha Riihimäki <juha.riihimaki@nokia.com> Cc: Alexander Graf <alex@csgraf.de> Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Fix compilation on Mac OS X v10.4 and earlierAndreas Färber1-7/+10
NSView's enterFullScreenMode:withOptions: and exitFullScreenModeWithOptions: are available on v10.5 and later only. Undefined methods raise warnings and undefined constants result in errors. Reported by Ryan Schmidt. While at it, avoid a warning on v10.3.9, where MAC_OS_X_VERSION_10_4 is not defined. Spotted by John Arbuckle. Fix associated comments. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: John Arbuckle <programmingkidx@gmail.com> Cc: Ryan Schmidt <qemu-2009@ryandesign.com> Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Silence type warningAndreas Färber1-1/+1
Add const for "qemu" character literal, to avoid: warning: initialization discards qualifiers from pointer target type An earlier patch by John proposed to use char[5]. Since we do not modify the text and later copy it into malloc'ed memory, marking it as const seems sufficient. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: John Arbuckle <programmingkidx@gmail.com> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Silence warning on Big Endian hostAndreas Färber1-1/+1
__LITTLE_ENDIAN__ is undefined on Big Endian host. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: John Arbuckle <programmingkidx@gmail.com> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: Silence warning for cocoa_keycode_to_qemuAndreas Färber1-1/+1
Make cocoa_keycode_to_qemu static, to avoid: warning: no previous prototype for ‘cocoa_keycode_to_qemu’ Signed-off-by: Andreas Färber <andreas.faerber@web.de> Cc: John Arbuckle <programmingkidx@gmail.com> Signed-off-by: malc <av1474@comtv.ru>
2010-01-07Cocoa: ppc64 host supportAndreas Färber1-0/+8
Fix integer usage in the Cocoa backend: NSInteger is long on LP64. http://developer.apple.com/mac/library/documentation/Cocoa/Reference/ApplicationKit/Classes/NSView_Class/Reference/NSView.html#//apple_ref/doc/uid/20000014-BBCFHHCD This makes the graphical display show up on a ppc64 host. v3: - Confine NSInteger to Mac OS X v10.5 and later Signed-off-by: Andreas Färber <andreas.faerber@web.de> Signed-off-by: malc <av1474@comtv.ru>
2009-03-04Update cocoa.m to match new DisplayState code (Samuel Benson)aliguori1-33/+20
Version 2 does as follows: [1]: Corrects endianness on issues by using native BGR to RGB conversion [2]: Uses DisplayState accessors for obtaining graphics context information, which [3]: Removes now unused variables, and [4]: Allows reading of varying color modes (32bit/24/16), and converting to native colorspace [5]: Attempts to keep itself centered on screen (as opposed to bottom right, which immediately goes off screen after bios load) on context changes (window resizes) Testing working on i386 (gentoo, Windows 2000) and PPC (debian) guests on PPC and x86 Macs. In regards to [4], Windows 2000 displays fine on quick tests, but on the lowest setting I could test, 16bit color depth at 4bpp, colors are slightly off. I used gentoo install-x86-minimal-2008.0 in framebuffer mode to test above setting; the usual grey text is now blue, and Tux appears to be BGR shifted. I do not know if previous code worked at such a low color setting. Signed-off-by: Samuel Benson <qemu_ml@digitalescape.info> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6683 c046a42c-6fe2-441c-8c8c-71466251a162
2008-03-10Let the USB tablet reach the far bottom and right pixelsaurel321-1/+1
(Samuel Thibault) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4036 c046a42c-6fe2-441c-8c8c-71466251a162
2008-01-22Core Graphics support (cocoa.m rewrite), by Mike Kronenberg.ths1-589/+650
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3929 c046a42c-6fe2-441c-8c8c-71466251a162
2007-11-17Break up vl.h.pbrook1-1/+3
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3674 c046a42c-6fe2-441c-8c8c-71466251a162
2007-09-17find -type f | xargs sed -i 's/[\t ]*$//g' # Yes, again. Note the star in ↵ths1-95/+95
the regex. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3177 c046a42c-6fe2-441c-8c8c-71466251a162
2007-09-16find -type f | xargs sed -i 's/[\t ]$//g' # on most filesths1-107/+107
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3173 c046a42c-6fe2-441c-8c8c-71466251a162
2007-06-10 Attempt to fix incorrect colours on some BGR displaysblueswir11-1/+6
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2974 c046a42c-6fe2-441c-8c8c-71466251a162
2006-06-14cocoa monitor fix regarding the handling of dead keys (Joachim Henke)bellard1-15/+32
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1975 c046a42c-6fe2-441c-8c8c-71466251a162
2006-05-22fix missing type declarations (Joachim Henke)bellard1-5/+4
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1932 c046a42c-6fe2-441c-8c8c-71466251a162
2006-04-16Remove stray "}".pbrook1-1/+0
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1817 c046a42c-6fe2-441c-8c8c-71466251a162
2006-04-09Allow multiple graphics devices.pbrook1-8/+5
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1803 c046a42c-6fe2-441c-8c8c-71466251a162
2005-12-18(Joachim Henke)bellard1-20/+23
- suppress unwanted kernel logs - avoids passing modifier keys to the guest OS when typing in the Monitor - fixes the bug that the mouse cursor grab is released with _any_ modifier key (should be only ctrl+alt) - removes some code redundancies git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1721 c046a42c-6fe2-441c-8c8c-71466251a162
2005-10-30fixed/full keyboard input - full mouse support - support for qemu console ↵bellard1-75/+373
(Mike Kronenberg) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1582 c046a42c-6fe2-441c-8c8c-71466251a162
2005-04-07accept more disk image extensions (David Still)bellard1-1/+1
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1359 c046a42c-6fe2-441c-8c8c-71466251a162
2005-04-07open the dialog box if an image was not selected from command-line (Pierre ↵bellard1-5/+10
d'Herbemont) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1358 c046a42c-6fe2-441c-8c8c-71466251a162
2005-03-02cocoa tiny fixesbellard1-1/+3
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1322 c046a42c-6fe2-441c-8c8c-71466251a162
2005-03-01initial Cocoa support (Pierre d'Herbemont)bellard1-0/+607
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1313 c046a42c-6fe2-441c-8c8c-71466251a162