Page 1 of 1

Unable ti switch from windowed screen to fullscreen

Posted: Wed Aug 11, 2004 4:21 am
by Nells
Hi !
I did this code

Code: Select all

Procedure switchScreen()
  CallDebugger
  If screen = 1
    CloseScreen()
    OpenWindow(0, 0, 0, 800, 600, #PB_Window_SystemMenu | #PB_Window_MinimizeGadget, #AppName)
    OpenWindowedScreen(WindowID(), 0, 0, 800, 600, 0, 0, 0)
    screen = 0
  Else
    CloseScreen()
    CloseWindow(0)
    If OpenScreen(#SCRWidth, #SCRHeight, #SCRDepth, #AppName)
      screen = 1
    Else
      MessageRequester(#AppName, "Impossible de passer au mode plein écran")
      OpenWindow(0, 0, 0, 800, 600, #PB_Window_SystemMenu | #PB_Window_MinimizeGadget, #AppName)
      OpenWindowedScreen(WindowID(), 0, 0, 800, 600, 0, 0, 0)
      screen = 0
    EndIf
  EndIf
EndProcedure
Yes, I'm french ^^

So, I got the message "Impossible de passer au mode plein écran" when I switched from fullscreen ^^

and full to windowed doesn't work neither

Could someone explain why it's impossible to switch, or maybe there's an error in the code?

Posted: Sat Aug 14, 2004 2:53 pm
by Nells
Nobody can help me? :cry:

Well, it's not that important, but can be useful ;)

Posted: Sat Aug 14, 2004 3:17 pm
by Shopro
hi,

you can find an example in the code archives. It contributed by myself :)

-Shopro

Posted: Sat Aug 14, 2004 7:43 pm
by Kale
Maybe this will help:
viewtopic.php?t=7772
:)

Posted: Sat Aug 14, 2004 9:07 pm
by Shopro
ah, yes, that's the one :)

-Shopro