VirtualBox

Changeset 6812 in vbox


Ignore:
Timestamp:
Feb 5, 2008 5:23:16 PM (17 years ago)
Author:
vboxsync
Message:

Mac OS X: For painting in the dock on 10.5 the blending mode has to be set explicitly.

Location:
trunk/src/VBox/Frontends/VirtualBox
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/include/VBoxUtils.h

    r6721 r6812  
    252252class VBoxFrameBuffer;
    253253CGImageRef DarwinQImageToCGImage (const QImage *aImage);
     254CGImageRef DarwinQImageFromMimeSourceToCGImage (const char *aSource);
    254255CGImageRef DarwinQPixmapToCGImage (const QPixmap *aPixmap);
    255256CGImageRef DarwinQPixmapFromMimeSourceToCGImage (const char *aSource);
  • trunk/src/VBox/Frontends/VirtualBox/src/darwin/VBoxUtils-darwin.cpp

    r6798 r6812  
    6969
    7070/**
     71 * Loads an image using Qt and converts it to a CGImage.
     72 *
     73 * @returns CGImageRef for the new image. (Remember to release it when finished with it.)
     74 * @param   aSource     The source name.
     75 */
     76CGImageRef DarwinQImageFromMimeSourceToCGImage (const char *aSource)
     77{
     78    QImage qim = QImage::fromMimeSource (aSource);
     79    Assert (!qim.isNull());
     80    return DarwinQImageToCGImage (&qim);
     81}
     82
     83/**
    7184 * Converts a QPixmap to a CGImage.
    7285 *
     
    166179    Assert (context);
    167180    /* Clear the background */
     181    CGContextSetBlendMode (context, kCGBlendModeNormal);
    168182    CGContextClearRect (context, CGRectMake (0, 0, 128, 128));
    169183    /* rounded corners */
     
    196210    if (aOverlayImage)
    197211    {
     212
    198213        CGRect overlayRect = CGRectMake (targetWidth - CGImageGetWidth (aOverlayImage),
    199214                                         0,
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette