[YAROTOWS] Reintegrate the branch. For a brighter future.
[reactos.git] / reactos / subsystems / win32 / win32k / eng / transblt.c
index b00c948..0bfc145 100644 (file)
@@ -12,9 +12,9 @@
  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  *  GNU General Public License for more details.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *  You should have received a copy of the GNU General Public License along
+ *  with this program; if not, write to the Free Software Foundation, Inc.,
+ *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 /* $Id$
  *
@@ -27,7 +27,7 @@
  *        4/6/2004: Created
  */
 
-#include <w32k.h>
+#include <win32k.h>
 
 #define NDEBUG
 #include <debug.h>
@@ -76,7 +76,7 @@ EngTransparentBlt(SURFOBJ *psoDest,
     OutputRect.top = DestRect->bottom;
     OutputRect.bottom = DestRect->top;
   }
-    
+
   if(Clip)
   {
     if(OutputRect.left < Clip->rclBounds.left)
@@ -143,7 +143,7 @@ EngTransparentBlt(SURFOBJ *psoDest,
       ClipRect.right = Clip->rclBounds.right + Translate.x;
       ClipRect.top = Clip->rclBounds.top + Translate.y;
       ClipRect.bottom = Clip->rclBounds.bottom + Translate.y;
-      if (EngIntersectRect(&CombinedRect, &OutputRect, &ClipRect))
+      if (RECTL_bIntersectRect(&CombinedRect, &OutputRect, &ClipRect))
       {
         InputToCombinedRect.top = InputRect.top + (CombinedRect.top - OutputRect.top) * SrcHeight / DstHeight;
         InputToCombinedRect.bottom = InputRect.top + (CombinedRect.bottom - OutputRect.top) * SrcHeight / DstHeight;
@@ -189,7 +189,7 @@ EngTransparentBlt(SURFOBJ *psoDest,
           ClipRect.right = RectEnum.arcl[i].right + Translate.x;
           ClipRect.top = RectEnum.arcl[i].top + Translate.y;
           ClipRect.bottom = RectEnum.arcl[i].bottom + Translate.y;
-          if (EngIntersectRect(&CombinedRect, &OutputRect, &ClipRect))
+          if (RECTL_bIntersectRect(&CombinedRect, &OutputRect, &ClipRect))
           {
             InputToCombinedRect.top = InputRect.top + (CombinedRect.top - OutputRect.top) * SrcHeight / DstHeight;
             InputToCombinedRect.bottom = InputRect.top + (CombinedRect.bottom - OutputRect.top) * SrcHeight / DstHeight;
@@ -264,7 +264,7 @@ IntEngTransparentBlt(SURFOBJ *psoDest,
    * outside the surface */
   if(Clip)
   {
-    if(!EngIntersectRect(&OutputRect, &InputClippedRect, &Clip->rclBounds))
+    if(!RECTL_bIntersectRect(&OutputRect, &InputClippedRect, &Clip->rclBounds))
     {
       return TRUE;
     }
@@ -284,17 +284,7 @@ IntEngTransparentBlt(SURFOBJ *psoDest,
     OutputRect = InputClippedRect;
   }
 
-  if(psoSource != psoDest)
-  {
-    SURFACE_LockBitmapBits(psurfSource);
-    MouseSafetyOnDrawStart(psoSource, InputRect.left, InputRect.top,
-                           InputRect.right, InputRect.bottom);
-  }
-  SURFACE_LockBitmapBits(psurfDest);
-  MouseSafetyOnDrawStart(psoDest, OutputRect.left, OutputRect.top,
-                         OutputRect.right, OutputRect.bottom);
-
-  if(psurfDest->flHooks & HOOK_TRANSPARENTBLT)
+  if(psurfDest->flags & HOOK_TRANSPARENTBLT)
   {
     Ret = GDIDEVFUNCS(psoDest).TransparentBlt(
       psoDest, psoSource, Clip, ColorTranslation, &OutputRect,
@@ -309,14 +299,6 @@ IntEngTransparentBlt(SURFOBJ *psoDest,
                             &OutputRect, &InputRect, iTransColor, Reserved);
   }
 
-  MouseSafetyOnDrawEnd(psoDest);
-  SURFACE_UnlockBitmapBits(psurfDest);
-  if(psoSource != psoDest)
-  {
-    MouseSafetyOnDrawEnd(psoSource);
-    SURFACE_UnlockBitmapBits(psurfSource);
-  }
-
   return Ret;
 }