comparison src/video/directfb/SDL_DirectFB_video.c @ 2259:1e690901ecd7

Date: Fri, 17 Aug 2007 01:12:31 +0200 From: Couriersud Subject: fix for audio dsp exit crash / various dfb issues improved cursor handling fixes some mouse and event related bugs
author Sam Lantinga <slouken@libsdl.org>
date Fri, 17 Aug 2007 02:54:50 +0000
parents b252359547ed
children e1da92da346c e82a0e3e9b0e
comparison
equal deleted inserted replaced
2258:771bd3389e3a 2259:1e690901ecd7
672 } else if (window->y == SDL_WINDOWPOS_UNDEFINED) { 672 } else if (window->y == SDL_WINDOWPOS_UNDEFINED) {
673 y = 0; 673 y = 0;
674 } else { 674 } else {
675 y = window->y; 675 y = window->y;
676 } 676 }
677 if (window->flags & SDL_WINDOW_FULLSCREEN) {
678 x = 0;
679 y = 0;
680 }
677 681
678 desc.flags = 682 desc.flags =
679 DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_CAPS | DWDESC_PIXELFORMAT; 683 DWDESC_WIDTH | DWDESC_HEIGHT | DWDESC_CAPS | DWDESC_PIXELFORMAT |
680 desc.flags |= DWDESC_POSX | DWDESC_POSY | DWDESC_SURFACE_CAPS; 684 DWDESC_SURFACE_CAPS;
681 desc.posx = x; 685 if (!(window->flags & SDL_WINDOW_FULLSCREEN)
682 desc.posy = y; 686 && window->x != SDL_WINDOWPOS_UNDEFINED
687 && window->y != SDL_WINDOWPOS_UNDEFINED) {
688 desc.flags |= DWDESC_POSX | DWDESC_POSY;
689 desc.posx = x;
690 desc.posy = y;
691 }
692
683 desc.width = window->w; 693 desc.width = window->w;
684 desc.height = window->h; 694 desc.height = window->h;
685
686 desc.pixelformat = dispdata->pixelformat; 695 desc.pixelformat = dispdata->pixelformat;
687
688 desc.caps = 0; //DWCAPS_DOUBLEBUFFER; 696 desc.caps = 0; //DWCAPS_DOUBLEBUFFER;
689 desc.surface_caps = DSCAPS_DOUBLE | DSCAPS_TRIPLE; //| DSCAPS_PREMULTIPLIED; 697 desc.surface_caps = DSCAPS_DOUBLE | DSCAPS_TRIPLE; //| DSCAPS_PREMULTIPLIED;
690 698
691 /* Create the window. */ 699 /* Create the window. */
692 SDL_DFB_CHECKERR(dispdata->layer-> 700 SDL_DFB_CHECKERR(dispdata->layer->
781 { 789 {
782 SDL_DFB_DEVICEDATA(_this); 790 SDL_DFB_DEVICEDATA(_this);
783 SDL_DFB_WINDOWDATA(window); 791 SDL_DFB_WINDOWDATA(window);
784 SDL_DFB_DISPLAYDATA(_this, window); 792 SDL_DFB_DISPLAYDATA(_this, window);
785 793
786 windata->window->MoveTo(windata->window, window->x, window->y); 794 if (!(window->flags & SDL_WINDOW_FULLSCREEN))
795 windata->window->MoveTo(windata->window, window->x, window->y);
787 } 796 }
788 797
789 static void 798 static void
790 DirectFB_SetWindowSize(_THIS, SDL_Window * window) 799 DirectFB_SetWindowSize(_THIS, SDL_Window * window)
791 { 800 {
792 SDL_DFB_DEVICEDATA(_this); 801 SDL_DFB_DEVICEDATA(_this);
793 SDL_DFB_WINDOWDATA(window); 802 SDL_DFB_WINDOWDATA(window);
794 SDL_DFB_DISPLAYDATA(_this, window); 803 SDL_DFB_DISPLAYDATA(_this, window);
795 804
796 windata->window->Resize(windata->window, window->w, window->h); 805 if (!(window->flags & SDL_WINDOW_FULLSCREEN))
797 806 windata->window->Resize(windata->window, window->w, window->h);
798 } 807 }
799 static void 808 static void
800 DirectFB_ShowWindow(_THIS, SDL_Window * window) 809 DirectFB_ShowWindow(_THIS, SDL_Window * window)
801 { 810 {
802 SDL_DFB_DEVICEDATA(_this); 811 SDL_DFB_DEVICEDATA(_this);