Index: trunk/src/VBox/Frontends/VirtualBox/VBoxUI.pro
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/VBoxUI.pro	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/VBoxUI.pro	(revision 6715)
@@ -267,5 +267,6 @@
 	images/dock_0.png \
 	images/dock_1.png \
-	images/dock_128x128_transparent.png
+	images/dock_128x128_transparent.png \
+	images/VirtualBox_48px.png
 
 TRANSLATIONS = \
Index: trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleView.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleView.h	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleView.h	(revision 6715)
@@ -283,4 +283,7 @@
 
     QPixmap mPausedShot;
+#if defined(Q_WS_MAC)
+    CGImageRef mVirtualBoxLogo;
+#endif
 };
 
Index: trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleWnd.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleWnd.h	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleWnd.h	(revision 6715)
@@ -336,9 +336,7 @@
 #ifdef Q_WS_MAC
     // Dock images.
-    CGImageRef dockImgStateRunning;
     CGImageRef dockImgStatePaused;
     CGImageRef dockImgStateSaving;
     CGImageRef dockImgStateRestoring;
-    CGImageRef dockImgBack75x75;
     CGImageRef dockImgBack100x75;
     CGImageRef dockImgOS;
Index: trunk/src/VBox/Frontends/VirtualBox/include/VBoxUtils.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/include/VBoxUtils.h	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/include/VBoxUtils.h	(revision 6715)
@@ -255,5 +255,5 @@
 CGImageRef DarwinQPixmapFromMimeSourceToCGImage (const char *aSource);
 CGImageRef DarwinCreateDockBadge (const char *aSource);
-CGImageRef DarwinCreateDockPreview (CGImageRef aVMImage, CGImageRef aOverlayImage);
+CGImageRef DarwinCreateDockPreview (CGImageRef aVMImage, CGImageRef aOverlayImage, CGImageRef aStateImage = NULL);
 CGImageRef DarwinCreateDockPreview (VBoxFrameBuffer *aFrameBuffer, CGImageRef aOverlayImage);
 OSStatus DarwinRegionHandler (EventHandlerCallRef aInHandlerCallRef, EventRef aInEvent, void *aInUserData);
Index: trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleView.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleView.cpp	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleView.cpp	(revision 6715)
@@ -625,4 +625,5 @@
 # endif
     , mDarwinKeyModifiers (0)
+    , mVirtualBoxLogo (NULL)
 #endif
 {
@@ -631,4 +632,9 @@
             !mConsole.GetKeyboard().isNull() &&
             !mConsole.GetMouse().isNull());
+
+#ifdef Q_WS_MAC
+    /* Overlay logo for the dock icon */
+    mVirtualBoxLogo = ::DarwinQPixmapFromMimeSourceToCGImage ("VirtualBox_48px.png");
+#endif
 
     /* enable MouseMove events */
@@ -798,4 +804,8 @@
 
     mConsole.UnregisterCallback (mCallback);
+
+#ifdef Q_WS_MAC
+    CGImageRelease (mVirtualBoxLogo);
+#endif
 }
 
@@ -2930,10 +2940,10 @@
                         static_cast <VBoxQuartz2DFrameBuffer *> (mFrameBuf)->imageRef();
                     SetApplicationDockTileImage (
-                        ::DarwinCreateDockPreview (ir, mMainWnd->dockImageState()));
+                        ::DarwinCreateDockPreview (ir, mVirtualBoxLogo));
                 }
                 else
 # endif
                     SetApplicationDockTileImage (
-                        ::DarwinCreateDockPreview (mFrameBuf, mMainWnd->dockImageState()));
+                        ::DarwinCreateDockPreview (mFrameBuf, mVirtualBoxLogo));
             }
 #endif
@@ -2947,4 +2957,11 @@
                         r.x() + contentsX(), r.y() + contentsY(),
                         r.width(), r.height());
+
+#ifdef Q_WS_MAC
+        SetApplicationDockTileImage (
+            ::DarwinCreateDockPreview (DarwinQPixmapToCGImage (&mPausedShot), 
+                                       mVirtualBoxLogo, 
+                                       mMainWnd->dockImageState()));
+#endif
     }
 }
Index: trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp	(revision 6715)
@@ -122,9 +122,7 @@
 #endif
 #ifdef Q_WS_MAC
-    , dockImgStateRunning (NULL)
     , dockImgStatePaused (NULL)
     , dockImgStateSaving (NULL)
     , dockImgStateRestoring (NULL)
-    , dockImgBack75x75 (NULL)
     , dockImgBack100x75 (NULL)
     , dockImgOS (NULL)
@@ -582,12 +580,9 @@
 #ifdef Q_WS_MAC
     /* prepare the dock images */
-    dockImgStateRunning   = ::DarwinCreateDockBadge ("state_running_16px.png");
     dockImgStatePaused    = ::DarwinCreateDockBadge ("state_paused_16px.png");
     dockImgStateSaving    = ::DarwinCreateDockBadge ("state_saving_16px.png");
     dockImgStateRestoring = ::DarwinCreateDockBadge ("state_restoring_16px.png");
-    dockImgBack75x75      = ::DarwinCreateDockBadge ("dock_0.png");
     dockImgBack100x75     = ::DarwinCreateDockBadge ("dock_1.png");
     SetApplicationDockTileImage (dockImgOS);
-    OverlayApplicationDockTileImage (dockImgStateRunning);
 #endif
     mMaskShift.scale (0, 0, QSize::ScaleFree);
@@ -598,6 +593,4 @@
 #ifdef Q_WS_MAC
     /* release the dock images */
-    if (dockImgStateRunning)
-        CGImageRelease (dockImgStateRunning);
     if (dockImgStatePaused)
         CGImageRelease (dockImgStatePaused);
@@ -606,6 +599,4 @@
     if (dockImgStateRestoring)
         CGImageRelease (dockImgStateRestoring);
-    if (dockImgBack75x75)
-        CGImageRelease (dockImgBack75x75);
     if (dockImgBack100x75)
         CGImageRelease (dockImgBack100x75);
@@ -800,11 +791,4 @@
 #ifdef Q_WS_MAC
     QString osTypeId = cmachine.GetOSTypeId();
-# if 0
-    QImage osImg75x75 = vboxGlobal().vmGuestOSTypeIcon (osTypeId).convertToImage().smoothScale (75, 75);
-    QImage osImg = QImage::fromMimeSource ("dock_0.png");
-    bitBlt (&osImg, 25, 22,
-            &osImg75x75, 0, 0,
-            75, 75, /* conversion_flags */ 0);
-# else
     QImage osImg100x75 = vboxGlobal().vmGuestOSTypeIcon (osTypeId).convertToImage().smoothScale (100, 75);
     QImage osImg = QImage::fromMimeSource ("dock_1.png");
@@ -812,8 +796,12 @@
             &osImg100x75, 0, 0,
             100, 75, /* conversion_flags */ 0);
-# endif
+    QImage VBoxOverlay = QImage::fromMimeSource ("VirtualBox_48px.png");
+    bitBlt (&osImg, osImg.width() - VBoxOverlay.width(), osImg.height() - VBoxOverlay.height(),
+            &VBoxOverlay, 0, 0,
+            VBoxOverlay.width(), VBoxOverlay.height(), /* conversion_flags */ 0);
     if (dockImgOS)
         CGImageRelease (dockImgOS);
     dockImgOS = ::DarwinQImageToCGImage (&osImg);
+    SetApplicationDockTileImage (dockImgOS);
 #endif
 
@@ -1909,11 +1897,4 @@
             vmDisableMouseIntegrAction->setEnabled (false);
     }
-
-#ifdef Q_WS_MAC
-    SetApplicationDockTileImage (dockImgOS);
-    CGImageRef img = dockImageState();
-    if (img)
-        OverlayApplicationDockTileImage (img);
-#endif
 }
 
@@ -2191,7 +2172,5 @@
 {
     CGImageRef img;
-    if (machine_state == CEnums::Running)
-        img = dockImgStateRunning;
-    else if (machine_state == CEnums::Paused)
+    if (machine_state == CEnums::Paused)
         img = dockImgStatePaused;
     else if (machine_state == CEnums::Restoring)
@@ -3170,4 +3149,10 @@
         }
     }
+
+#ifdef Q_WS_MAC
+    CGImageRef img = dockImageState();
+    if (img)
+        OverlayApplicationDockTileImage (img);
+#endif
 }
 
Index: trunk/src/VBox/Frontends/VirtualBox/src/darwin/VBoxUtils-darwin.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/darwin/VBoxUtils-darwin.cpp	(revision 6714)
+++ trunk/src/VBox/Frontends/VirtualBox/src/darwin/VBoxUtils-darwin.cpp	(revision 6715)
@@ -118,7 +118,10 @@
     if (badge.width() < 32)
         badge = badge.convertToImage().smoothScale (32, 32);
-    copyBlt (&back, back.width() - badge.width(), back.height() - badge.height(),
+    copyBlt (&back, (back.width() - badge.width()) / 2.0, (back.height() - badge.height()) / 2.0,
              &badge, 0, 0,
              badge.width(), badge.height());
+//    copyBlt (&back, back.width() - badge.width(), back.height() - badge.height(),
+//             &badge, 0, 0,
+//             badge.width(), badge.height());
     Assert (!back.isNull());
     Assert (back.width() == 128 && back.height() == 128);
@@ -128,5 +131,4 @@
 }
 
-
 /**
  * Creates a dock preview image.
@@ -136,7 +138,8 @@
  * @returns CGImageRef for the new image. (Remember to release it when finished with it.)
  * @param   aVMImage   the vm screen as a CGImageRef
- * @param   aOverlayImage   an optional overlay image to add at the bottom right of the icon
- */
-CGImageRef DarwinCreateDockPreview (CGImageRef aVMImage, CGImageRef aOverlayImage)
+ * @param   aOverlayImage   an optional icon overlay image to add at the bottom right of the icon
+ * @param   aStateImage   an optional state overlay image to add at the center of the icon
+ */
+CGImageRef DarwinCreateDockPreview (CGImageRef aVMImage, CGImageRef aOverlayImage, CGImageRef aStateImage)
 {
     Assert (aVMImage);
@@ -189,5 +192,11 @@
         iconRect = CGRectInset (iconRect, 1, 1);
         CGContextDrawImage (context, iconRect, aVMImage);
-        /* the overlay image */
+        /* the state image at center */
+        if (aStateImage)
+        {
+            CGRect stateRect = CGRectMake ((targetWidth - CGImageGetWidth (aStateImage)) / 2.0, (targetHeight - CGImageGetHeight (aStateImage)) / 2.0, CGImageGetWidth (aStateImage), CGImageGetHeight (aStateImage));
+            CGContextDrawImage (context, stateRect, aStateImage);
+        }
+        /* the overlay image at bottom/right */
         if (aOverlayImage)
         {
@@ -214,5 +223,5 @@
  * @returns CGImageRef for the new image. (Remember to release it when finished with it.)
  * @param   aFrameBuffer    The guest frame buffer.
- * @param   aOverlayImage   an optional overlay image to add at the bottom right of the icon
+ * @param   aOverlayImage   an optional icon overlay image to add at the bottom right of the icon
  */
 CGImageRef DarwinCreateDockPreview (VBoxFrameBuffer *aFrameBuffer, CGImageRef aOverlayImage)
