Changeset eb3609cdde05a5208ed9be0b84280fcd0234ae61

Show
Ignore:
Timestamp:
04/13/03 00:50:42 (5 years ago)
Author:
Cyril Deguet <asmax@videolan.org>
git-committer:
Cyril Deguet <asmax@videolan.org> 1050187842 +0000
git-parent:

[f3bcd927cd924fc64418b5dbf5cce31f8b483553]

git-author:
Cyril Deguet <asmax@videolan.org> 1050187842 +0000
Message:

* now the skin module compiles AND links !

(and segfaults... ;)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/gui/skins/controls/text.cpp

    ra64501f reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: text.cpp,v 1.1 2003/03/18 02:21:47 ipkiss Exp $ 
     5 * $Id: text.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Olivier Teuli� <ipkiss@via.ecp.fr> 
     
    4949//--------------------------------------------------------------------------- 
    5050 
     51    #if defined( WIN32 ) 
    5152    //----------------------------------------------------------------------- 
    5253    // Win32 methods 
    5354    //----------------------------------------------------------------------- 
    54     #if defined( WIN32 ) 
    5555    void CALLBACK ScrollingTextTimer( HWND hwnd, UINT uMsg, UINT_PTR idEvent, 
    5656        DWORD dwTime ) 
     
    7474        KillTimer( ( (Win32Window *)ParentWindow )->GetHandle(), 
    7575                   (UINT_PTR)this ); 
     76    } 
     77    //----------------------------------------------------------------------- 
     78 
     79    #else 
     80    //----------------------------------------------------------------------- 
     81    // Gtk2 methods 
     82    //----------------------------------------------------------------------- 
     83    void ControlText::StartScrolling() 
     84    { 
     85/* FIXME: kluge */ 
     86 /*       SetTimer( ( (Win32Window *)ParentWindow )->GetHandle(), (UINT_PTR)this, 
     87                  100, (TIMERPROC)ScrollingTextTimer );*/ 
     88    } 
     89    //----------------------------------------------------------------------- 
     90    void ControlText::StopScrolling() 
     91    { 
     92/*        KillTimer( ( (Win32Window *)ParentWindow )->GetHandle(), 
     93                   (UINT_PTR)this );*/ 
    7694    } 
    7795    //----------------------------------------------------------------------- 
  • modules/gui/skins/gtk2/gtk2_api.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_api.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_api.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet  <asmax@videolan.org> 
     
    3333#include "event.h"         // for MAX_PARAM_SIZE 
    3434 
    35 /* 
    3635 
    3736//--------------------------------------------------------------------------- 
     
    4140                        long param2 ) 
    4241{ 
    43     if( win == NULL ) 
     42/*    if( win == NULL ) 
    4443        SendMessage( NULL, message, param1, param2 ); 
    4544    else 
    4645        SendMessage( ( (Win32Window *)win )->GetHandle(), message, param1, 
    47                      param2 ); 
     46                     param2 );*/ 
    4847} 
    4948//--------------------------------------------------------------------------- 
     
    5150                        long param2 ) 
    5251{ 
    53     if( win == NULL ) 
     52/*    if( win == NULL ) 
    5453        PostMessage( NULL, message, param1, param2 ); 
    5554    else 
    5655        PostMessage( ( (Win32Window *)win )->GetHandle(), message, param1, 
    57                      param2 ); 
     56                     param2 );*/ 
    5857} 
    5958//--------------------------------------------------------------------------- 
     
    6766int OSAPI_GetNonTransparentColor( int c ) 
    6867{ 
    69     // Get desktop device context 
     68/*    // Get desktop device context 
    7069    HDC DeskDC = GetWindowDC( GetDesktopWindow() ); 
    7170 
     
    7978    } 
    8079    ReleaseDC( GetDesktopWindow(), DeskDC ); 
    81     return c; 
     80    return c;*/ 
    8281} 
    8382//--------------------------------------------------------------------------- 
     
    9190int OSAPI_GetTime() 
    9291{ 
    93     return GetTickCount(); 
     92/*    return GetTickCount();*/ 
    9493} 
    9594//--------------------------------------------------------------------------- 
    9695void OSAPI_GetScreenSize( int &w, int &h ) 
    9796{ 
    98     w = GetSystemMetrics(SM_CXSCREEN); 
    99     h = GetSystemMetrics(SM_CYSCREEN); 
     97/*    w = GetSystemMetrics(SM_CXSCREEN); 
     98    h = GetSystemMetrics(SM_CYSCREEN);*/ 
    10099} 
    101100//--------------------------------------------------------------------------- 
    102101void OSAPI_GetMousePos( int &x, int &y ) 
    103102{ 
    104     LPPOINT MousePos = new POINT; 
     103/*    LPPOINT MousePos = new POINT; 
    105104    GetCursorPos( MousePos ); 
    106105    x = MousePos->x; 
    107106    y = MousePos->y; 
    108     delete MousePos; 
     107    delete MousePos;*/ 
    109108} 
    110109//--------------------------------------------------------------------------- 
    111110string OSAPI_GetWindowTitle( Window *win ) 
    112111{ 
    113     char *buffer = new char[MAX_PARAM_SIZE]; 
     112/*    char *buffer = new char[MAX_PARAM_SIZE]; 
    114113    GetWindowText( ((Win32Window *)win)->GetHandle(), buffer, MAX_PARAM_SIZE ); 
    115114    string Title = buffer; 
    116115    delete buffer; 
    117116 
    118     return Title; 
     117    return Title;*/ 
    119118} 
    120119//--------------------------------------------------------------------------- 
    121120bool OSAPI_RmDir( string path ) 
    122121{ 
    123     WIN32_FIND_DATA find; 
     122/*    WIN32_FIND_DATA find; 
    124123    string File; 
    125124    string FindFiles = path + "\\*.*"; 
     
    155154    RemoveDirectory( (char *)path.c_str() ); 
    156155 
    157     return true; 
     156    return true;*/ 
    158157} 
    159158//--------------------------------------------------------------------------- 
    160 */ 
     159 
  • modules/gui/skins/gtk2/gtk2_dialog.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_dialog.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_dialog.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    4747#include "os_api.h" 
    4848 
    49 /* 
     49 
    5050//--------------------------------------------------------------------------- 
    5151// Open file dialog box 
     
    6262void GTK2OpenFileDialog::AddFilter( string name, string type ) 
    6363{ 
    64     unsigned int i; 
     64/*    unsigned int i; 
    6565 
    6666    for( i = 0; i < name.length(); i++ ) 
     
    8282 
    8383    // Ending null character if this filter is the last 
    84     Filter[FilterLength] = '\0'; 
     84    Filter[FilterLength] = '\0';*/ 
    8585} 
    8686//--------------------------------------------------------------------------- 
     
    8888{ 
    8989    // Initailize dialog box 
    90     OPENFILENAME OpenFile; 
     90/*    OPENFILENAME OpenFile; 
    9191    memset( &OpenFile, 0, sizeof( OpenFile ) ); 
    9292    OpenFile.lStructSize  = sizeof( OPENFILENAME ); 
     
    181181    delete[] OpenFile.lpstrFile; 
    182182 
    183     return true; 
     183    return true;*/ 
    184184} 
    185185//--------------------------------------------------------------------------- 
     
    191191// CALLBACKs 
    192192//--------------------------------------------------------------------------- 
    193 LRESULT CALLBACK LogWindowProc( HWND hwnd, UINT uMsg, WPARAM wParam, 
     193/*LRESULT CALLBACK LogWindowProc( HWND hwnd, UINT uMsg, WPARAM wParam, 
    194194                                LPARAM lParam ) 
    195195{ 
     
    247247    delete (string *)dwCookie; 
    248248    return 0; 
    249 } 
     249}*/ 
    250250//--------------------------------------------------------------------------- 
    251251 
     
    257257GTK2LogWindow::GTK2LogWindow( intf_thread_t *_p_intf ) : LogWindow( _p_intf ) 
    258258{ 
    259     hWindow   = NULL; 
     259/*    hWindow   = NULL; 
    260260    hRichCtrl = NULL; 
    261261 
     
    300300    RtfHeader = "{\\rtf1 "; 
    301301 
    302     Clear(); 
     302    Clear();*/ 
    303303} 
    304304//--------------------------------------------------------------------------- 
    305305GTK2LogWindow::~GTK2LogWindow() 
    306306{ 
    307     DestroyWindow( hRichCtrl ); 
    308     DestroyWindow( hWindow ); 
     307/*    DestroyWindow( hRichCtrl ); 
     308    DestroyWindow( hWindow );*/ 
    309309} 
    310310//--------------------------------------------------------------------------- 
    311311void GTK2LogWindow::Clear() 
    312312{ 
    313     EDITSTREAM *Stream; 
     313/*    EDITSTREAM *Stream; 
    314314    Stream = new EDITSTREAM; 
    315315    string *buffer = new string( RtfHeader ); 
     
    317317    Stream->dwError  = 0; 
    318318    Stream->pfnCallback = (EDITSTREAMCALLBACK)LogWindowStream; 
    319     SendMessage( hRichCtrl, EM_STREAMIN, SF_RTF, (LPARAM)Stream ); 
     319    SendMessage( hRichCtrl, EM_STREAMIN, SF_RTF, (LPARAM)Stream );*/ 
    320320} 
    321321//--------------------------------------------------------------------------- 
     
    323323{ 
    324324    // Initialize stream 
    325         EDITSTREAM *Stream; 
     325/*        EDITSTREAM *Stream; 
    326326        string *buffer      = new string( RtfHeader + line + "\\par }" ); 
    327327        Stream              = new EDITSTREAM; 
     
    332332    SendMessage( hRichCtrl, EM_STREAMIN, SF_RTF|SFF_SELECTION, (LPARAM)Stream ); 
    333333 
    334     SendMessage( hRichCtrl, WM_VSCROLL, SB_BOTTOM, 0 ); 
     334    SendMessage( hRichCtrl, WM_VSCROLL, SB_BOTTOM, 0 );*/ 
    335335} 
    336336//--------------------------------------------------------------------------- 
    337337void GTK2LogWindow::ChangeColor( int color, bool bold ) 
    338338{ 
    339     CHARFORMAT format; 
     339/*    CHARFORMAT format; 
    340340    memset(&format, 0, sizeof(CHARFORMAT)); 
    341341    format.cbSize      = sizeof(CHARFORMAT); 
     
    343343    format.dwEffects   = bold ? CFE_BOLD           : 0; 
    344344    format.crTextColor = color; 
    345     SendMessage( hRichCtrl, EM_SETCHARFORMAT, SCF_SELECTION, (LPARAM)&format ); 
     345    SendMessage( hRichCtrl, EM_SETCHARFORMAT, SCF_SELECTION, (LPARAM)&format );*/ 
    346346} 
    347347//--------------------------------------------------------------------------- 
    348348void GTK2LogWindow::Show() 
    349349{ 
    350     ShowWindow( hWindow, SW_SHOW ); 
    351     Visible = true; 
     350/*    ShowWindow( hWindow, SW_SHOW ); 
     351    Visible = true;*/ 
    352352} 
    353353//--------------------------------------------------------------------------- 
    354354void GTK2LogWindow::Hide() 
    355355{ 
    356     ShowWindow( hWindow, SW_HIDE ); 
    357     Visible = false; 
    358 } 
    359 //--------------------------------------------------------------------------- 
    360 */ 
     356/*    ShowWindow( hWindow, SW_HIDE ); 
     357    Visible = false;*/ 
     358} 
     359//--------------------------------------------------------------------------- 
     360 
  • modules/gui/skins/gtk2/gtk2_event.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_event.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_event.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    4040 
    4141 
    42 /* 
    4342//--------------------------------------------------------------------------- 
    4443//   VLC Event 
     
    4746    : Event( p_intf, Desc, shortcut ) 
    4847{ 
    49     hWnd = NULL; 
     48/*    hWnd = NULL;*/ 
    5049} 
    5150//--------------------------------------------------------------------------- 
    52 GTK2Event::GTK2Event( intf_thread_t *p_intf, HWND hwnd, unsigned int msg, 
     51GTK2Event::GTK2Event( intf_thread_t *p_intf, GdkWindow *gwnd, unsigned int msg, 
    5352    unsigned int par1, long par2 ) : Event( p_intf, msg, par1, par2 ) 
    5453{ 
    55     hWnd = hwnd; 
     54/*    hWnd = hwnd;*/ 
    5655} 
    5756//--------------------------------------------------------------------------- 
     
    5958    unsigned int par1, long par2 ) : Event( p_intf, msg, par1, par2 ) 
    6059{ 
    61     hWnd = ( (GTK2Window *)win )->GetHandle(); 
     60/*    hWnd = ( (GTK2Window *)win )->GetHandle();*/ 
    6261} 
    6362//--------------------------------------------------------------------------- 
     
    6867bool GTK2Event::SendEvent() 
    6968{ 
    70     if( Message != VLC_NOTHING ) 
     69/*    if( Message != VLC_NOTHING ) 
    7170    { 
    7271        PostMessage( hWnd, Message, Param1, Param2 ); 
     
    7675 
    7776    return true; 
    78  
     77*/ 
    7978} 
    8079//--------------------------------------------------------------------------- 
    8180bool GTK2Event::IsEqual( Event *evt ) 
    8281{ 
    83     GTK2Event *WinEvt = (GTK2Event *)evt; 
     82/*    GTK2Event *WinEvt = (GTK2Event *)evt; 
    8483    return( WinEvt->GetWindow() == hWnd   && WinEvt->GetMessage() == Message && 
    85             WinEvt->GetParam1() == Param1 && WinEvt->GetParam2()  == Param2 ); 
     84            WinEvt->GetParam1() == Param1 && WinEvt->GetParam2()  == Param2 );*/ 
    8685} 
    8786//--------------------------------------------------------------------------- 
    8887void GTK2Event::CreateOSEvent( string para1, string para2, string para3 ) 
    8988{ 
    90  
     89/* 
    9190    // Find Parameters 
    9291    switch( Message ) 
     
    105104 
    106105    } 
    107  
     106*/ 
    108107} 
    109108//--------------------------------------------------------------------------- 
    110 HWND GTK2Event::GetWindowFromName( string name ) 
     109GdkWindow *GTK2Event::GetWindowFromName( string name ) 
    111110{ 
    112     GTK2Window *win = (GTK2Window *) 
     111/*    GTK2Window *win = (GTK2Window *) 
    113112        p_intf->p_sys->p_theme->GetWindow( name ); 
    114113    if( win == NULL ) 
    115114        return NULL; 
    116115    else 
    117         return win->GetHandle(); 
     116        return win->GetHandle();*/ 
    118117} 
    119118//--------------------------------------------------------------------------- 
    120 */ 
     119 
  • modules/gui/skins/gtk2/gtk2_font.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_font.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_font.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    3737 
    3838 
    39 /* 
     39 
    4040//--------------------------------------------------------------------------- 
    4141// Font object 
     
    5151} 
    5252//--------------------------------------------------------------------------- 
    53 void GTK2Font::AssignGTK2Font( HDC DC ) 
     53/*void GTK2Font::AssignGTK2Font( HDC DC ) 
    5454{ 
    5555    // Create font 
     
    7676    // Free memory 
    7777    DeleteObject( fontObj ); 
    78 } 
     78}*/ 
    7979//--------------------------------------------------------------------------- 
    8080void GTK2Font::AssignFont( Graphics *dest ) 
    81 { 
     81{/* 
    8282    HDC DC = ( (GTK2Graphics *)dest )->GetImageHandle(); 
    83     AssignGTK2Font( DC ); 
     83    AssignGTK2Font( DC );*/ 
    8484} 
    8585//--------------------------------------------------------------------------- 
    8686void GTK2Font::GetSize( string text, int &w, int &h ) 
    8787{ 
    88     // Get device context of screen 
     88/*    // Get device context of screen 
    8989    HDC DeskDC = GetWindowDC( GetDesktopWindow() ); 
    9090 
     
    9999 
    100100    // Release screen device context 
    101     ReleaseDC( GetDesktopWindow(), DeskDC ); 
     101    ReleaseDC( GetDesktopWindow(), DeskDC );*/ 
    102102} 
    103103//--------------------------------------------------------------------------- 
     
    105105                                 int w, int h, int align, int color ) 
    106106{ 
    107     HDC DC = ( (GTK2Graphics *)dest )->GetImageHandle(); 
     107/*    HDC DC = ( (GTK2Graphics *)dest )->GetImageHandle(); 
    108108    // Set boundaries 
    109109    LPRECT r = new RECT; 
     
    129129 
    130130    // Free memory 
    131     delete r; 
     131    delete r;*/ 
    132132} 
    133133 
     
    136136                       int h, int align ) 
    137137{ 
    138     GenericPrint( dest, text, x, y, w, h, align, Color ); 
     138/*    GenericPrint( dest, text, x, y, w, h, align, Color );*/ 
    139139} 
    140140//--------------------------------------------------------------------------- 
     
    142142                            int h, int align, int color ) 
    143143{ 
    144     GenericPrint( dest, text, x, y, w, h, align, color ); 
     144/*    GenericPrint( dest, text, x, y, w, h, align, color );*/ 
    145145} 
    146146//--------------------------------------------------------------------------- 
    147147 
    148 */ 
  • modules/gui/skins/gtk2/gtk2_graphics.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_graphics.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_graphics.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    3434 
    3535 
    36 /* 
    3736//--------------------------------------------------------------------------- 
    3837// GTK2 GRAPHICS 
     
    4039GTK2Graphics::GTK2Graphics( int w, int h, Window *from ) : Graphics( w, h ) 
    4140{ 
    42     HBITMAP HImage ; 
     41/*    HBITMAP HImage ; 
    4342    Image          = CreateCompatibleDC( NULL ); 
    4443    if( from != NULL ) 
     
    5352    } 
    5453    SelectObject( Image, HImage ); 
    55     DeleteObject( HImage ); 
     54    DeleteObject( HImage );*/ 
    5655} 
    5756//--------------------------------------------------------------------------- 
    5857GTK2Graphics::~GTK2Graphics() 
    5958{ 
    60     DeleteDC( Image ); 
     59/*    DeleteDC( Image );*/ 
    6160} 
    6261//--------------------------------------------------------------------------- 
     
    6463                              int sx, int sy, int Flag ) 
    6564{ 
    66     BitBlt( Image, dx, dy, dw, dh, ( (GTK2Graphics *)Src )->GetImageHandle(), 
    67         sx, sy, Flag ); 
     65/*    BitBlt( Image, dx, dy, dw, dh, ( (GTK2Graphics *)Src )->GetImageHandle(), 
     66        sx, sy, Flag );*/ 
    6867} 
    69 */ 
     68 
    7069//--------------------------------------------------------------------------- 
    7170/*void GTK2Graphics::CopyTo( Graphics *Dest, int dx, int dy, int dw, int dh, 
     
    7473    BitBlt( ( (GTK2Graphics *)Dest )->GetImageHandle(), dx, dy, dw, dh, Image, 
    7574        sx, sy, Flag ); 
    76 }*//* 
     75}*/ 
    7776//--------------------------------------------------------------------------- 
    7877void GTK2Graphics::DrawRect( int x, int y, int w, int h, int color ) 
    7978{ 
    80     LPRECT r = new RECT; 
     79/*    LPRECT r = new RECT; 
    8180    HBRUSH  Brush = CreateSolidBrush( color ); 
    8281    r->left   = x; 
     
    8685    FillRect( Image, r, Brush ); 
    8786    DeleteObject( Brush ); 
    88     delete r; 
     87    delete r;*/ 
    8988} 
    9089//--------------------------------------------------------------------------- 
    9190void GTK2Graphics::SetClipRegion( Region *rgn ) 
    9291{ 
    93     SelectClipRgn( Image, ( (GTK2Region *)rgn )->GetHandle() ); 
     92/*    SelectClipRgn( Image, ( (GTK2Region *)rgn )->GetHandle() );*/ 
    9493} 
    9594//--------------------------------------------------------------------------- 
     
    103102GTK2Region::GTK2Region() 
    104103{ 
    105     Rgn = CreateRectRgn( 0, 0, 0, 0 ); 
     104/*    Rgn = CreateRectRgn( 0, 0, 0, 0 );*/ 
    106105} 
    107106//--------------------------------------------------------------------------- 
    108107GTK2Region::GTK2Region( int x, int y, int w, int h ) 
    109108{ 
    110     Rgn = CreateRectRgn( x, y, x + w, y + h ); 
     109/*    Rgn = CreateRectRgn( x, y, x + w, y + h );*/ 
    111110} 
    112111//--------------------------------------------------------------------------- 
    113112GTK2Region::~GTK2Region() 
    114113{ 
    115     DeleteObject( Rgn ); 
     114/*    DeleteObject( Rgn );*/ 
    116115} 
    117116//--------------------------------------------------------------------------- 
    118117void GTK2Region::AddPoint( int x, int y ) 
    119118{ 
    120     AddRectangle( x, y, x + 1, y + 1 ); 
     119/*    AddRectangle( x, y, x + 1, y + 1 );*/ 
    121120} 
    122121//--------------------------------------------------------------------------- 
    123122void GTK2Region::AddRectangle( int x, int y, int w, int h ) 
    124123{ 
    125     HRGN Buffer; 
     124/*    HRGN Buffer; 
    126125    Buffer = CreateRectRgn( x, y, x + w, y + h ); 
    127126    CombineRgn( Rgn, Buffer, Rgn, 0x2 ); 
    128     DeleteObject( Buffer ); 
     127    DeleteObject( Buffer );*/ 
    129128} 
    130129//--------------------------------------------------------------------------- 
    131130void GTK2Region::AddElipse( int x, int y, int w, int h ) 
    132131{ 
    133     HRGN Buffer; 
     132/*    HRGN Buffer; 
    134133    Buffer = CreateEllipticRgn( x, y, x + w, y + h ); 
    135134    CombineRgn( Rgn, Buffer, Rgn, 0x2 ); 
    136     DeleteObject( Buffer ); 
     135    DeleteObject( Buffer );*/ 
    137136} 
    138137//--------------------------------------------------------------------------- 
    139138void GTK2Region::Move( int x, int y ) 
    140139{ 
    141     OffsetRgn( Rgn, x, y ); 
     140/*    OffsetRgn( Rgn, x, y );*/ 
    142141} 
    143142//--------------------------------------------------------------------------- 
    144143bool GTK2Region::Hit( int x, int y ) 
    145144{ 
    146     return PtInRegion( Rgn, x, y ); 
     145/*    return PtInRegion( Rgn, x, y );*/ 
    147146} 
    148147//--------------------------------------------------------------------------- 
    149 */ 
     148 
  • modules/gui/skins/gtk2/gtk2_run.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_run.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_run.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    4343 
    4444 
    45 #if 0 
    46  
    4745//--------------------------------------------------------------------------- 
    4846// Specific method 
     
    5654// REFRESH TIMER CALLBACK 
    5755//--------------------------------------------------------------------------- 
    58 void CALLBACK RefreshTimer( HWND hwnd, UINT uMsg, UINT idEvent, DWORD dwTime ) 
     56/*void CALLBACK RefreshTimer( HWND hwnd, UINT uMsg, UINT idEvent, DWORD dwTime ) 
    5957{ 
    6058    intf_thread_t *p_intf = (intf_thread_t *)GetWindowLongPtr( hwnd, 
    6159        GWLP_USERDATA ); 
    6260    SkinManage( p_intf ); 
    63 } 
     61}*/ 
    6462//--------------------------------------------------------------------------- 
    6563 
     
    7169void OSRun( intf_thread_t *p_intf ) 
    7270{ 
     71#if 0 
    7372    VlcProc *Proc = new VlcProc( p_intf ); 
    7473    MSG msg; 
     
    172171        Proc->IsClosing(); 
    173172    } 
     173    #endif 
    174174} 
    175175//--------------------------------------------------------------------------- 
     
    181181 
    182182 
    183 #endif 
  • modules/gui/skins/gtk2/gtk2_window.cpp

    rf3bcd92 reb3609c  
    33 ***************************************************************************** 
    44 * Copyright (C) 2003 VideoLAN 
    5  * $Id: gtk2_window.cpp,v 1.1 2003/04/12 21:43:27 asmax Exp $ 
     5 * $Id: gtk2_window.cpp,v 1.2 2003/04/12 22:50:42 asmax Exp $ 
    66 * 
    77 * Authors: Cyril Deguet     <asmax@videolan.org> 
     
    4747 
    4848 
    49 /* 
     49 
    5050//--------------------------------------------------------------------------- 
    5151// Fading API 
    5252//--------------------------------------------------------------------------- 
    53 #define LWA_COLORKEY  0x00000001 
     53/*#define LWA_COLORKEY  0x00000001 
    5454#define LWA_ALPHA     0x00000002 
    5555typedef BOOL (WINAPI *SLWA)(HWND, COLORREF, BYTE, DWORD); 
     
    5757SLWA SetLayeredWindowAttributes = 
    5858    (SLWA)GetProcAddress( hModule, "SetLayeredWindowAttributes" ); 
    59  
     59*/ 
    6060 
    6161//--------------------------------------------------------------------------- 
    6262// Skinable Window 
    6363//--------------------------------------------------------------------------- 
    64 GTK2Window::GTK2Window( intf_thread_t *p_intf, HWND hwnd, int x, int y, 
     64GTK2Window::GTK2Window( intf_thread_t *p_intf, GdkWindow *gwnd, int x, int y, 
    6565    bool visible, int transition, int normalalpha, int movealpha, 
    6666    bool dragdrop ) 
     
    6969{ 
    7070    // Set handles 
    71     hWnd           = hwnd; 
     71/*    hWnd           = hwnd; 
    7272 
    7373    // Set position parameters 
     
    103103        RegisterDragDrop( hWnd, DropTarget ); 
    104104    } 
    105  
     105*/ 
    106106} 
    107107//--------------------------------------------------------------------------- 
    108108GTK2Window::~GTK2Window() 
    109109{ 
    110     delete CursorPos; 
     110/*    delete CursorPos; 
    111111    delete WindowPos; 
    112112 
     
    127127        OleUninitialize(); 
    128128    } 
    129  
     129*/ 
    130130} 
    131131//--------------------------------------------------------------------------- 
    132132void GTK2Window::OSShow( bool show ) 
    133133{ 
    134     if( show ) 
     134/*    if( show ) 
    135135    { 
    136136        ShowWindow( hWnd, SW_SHOW ); 
     
    139139    { 
    140140        ShowWindow( hWnd, SW_HIDE ); 
    141     } 
     141    }*/ 
    142142} 
    143143//--------------------------------------------------------------------------- 
    144144bool GTK2Window::ProcessOSEvent( Event *evt ) 
    145145{ 
    146     unsigned int msg = evt->GetMessage(); 
     146/*    unsigned int msg = evt->GetMessage(); 
    147147    unsigned int p1  = evt->GetParam1(); 
    148148    int          p2  = evt->GetParam2(); 
     
    202202        default: 
    203203            return false; 
    204     } 
     204    }*/ 
    205205} 
    206206//--------------------------------------------------------------------------- 
    207207void GTK2Window::SetTransparency( int Value ) 
    208208{ 
    209     if( Value > -1 ) 
     209/*    if( Value > -1 ) 
    210210        Alpha = Value; 
    211211    SetLayeredWindowAttributes( hWnd, 0, Alpha, LWA_ALPHA | LWA_COLORKEY ); 
    212     UpdateWindow( hWnd ); 
     212    UpdateWindow( hWnd );*/ 
    213213} 
    214214//--------------------------------------------------------------------------- 
     
    216216{ 
    217217    // Initialize painting 
    218     HDC DC = GetWindowDC( hWnd ); 
     218/*    HDC DC = GetWindowDC( hWnd ); 
    219219 
    220220    // Draw image on window 
     
    224224    // Release window device context 
    225225    ReleaseDC( hWnd, DC ); 
    226  
     226*/ 
    227227} 
    228228//--------------------------------------------------------------------------- 
    229229void GTK2Window::WindowManualMove() 
    230230{ 
    231     // Get mouse cursor position 
     231/*    // Get mouse cursor position 
    232232    LPPOINT NewPos = new POINT; 
    233233    GetCursorPos( NewPos ); 
     
    240240    // Free memory 
    241241    delete[] NewPos; 
    242  
     242*/ 
    243243} 
    244244//--------------------------------------------------------------------------- 
    245245void GTK2Window::WindowManualMoveInit() 
    246246{ 
    247     GetCursorPos( CursorPos ); 
     247/*    GetCursorPos( CursorPos ); 
    248248    WindowPos->x = Left; 
    249     WindowPos->y = Top; 
     249    WindowPos->y = Top;*/ 
    250250} 
    251251//--------------------------------------------------------------------------- 
    252252void GTK2Window::Move( int left, int top ) 
    253253{ 
    254     Left = left; 
     254/*    Left = left; 
    255255    Top  = top; 
    256256    //SetWindowPos( hWnd, HWND_TOP, Left, Top, Width, Height, 
    257257    //              SWP_NOSIZE|SWP_NOREDRAW|SWP_NOZORDER ); 
    258     MoveWindow( hWnd, Left, Top, Width, Height, false ); 
     258    MoveWindow( hWnd, Left, Top, Width, Height, false );*/ 
    259259} 
    260260//--------------------------------------------------------------------------- 
    261261void GTK2Window::Size( int width, int height ) 
    262262{ 
    263     Width  = width; 
     263/*    Width  = width; 
    264264    Height = height; 
    265265    SetWindowPos( hWnd, HWND_TOP, Left, Top, Width, Height, 
    266                   SWP_NOMOVE|SWP_NOREDRAW|SWP_NOZORDER ); 
     266                  SWP_NOMOVE|SWP_NOREDRAW|SWP_NOZORDER );*/ 
    267267} 
    268268//--------------------------------------------------------------------------- 
    269269void GTK2Window::ChangeToolTipText( string text ) 
    270270{ 
    271     if( text == "none" ) 
     271/*    if( text == "none" ) 
    272272    { 
    273273        if( ToolTipText != "none" ) 
     
    289289        } 
    290290    } 
    291  
    292 } 
    293 //--------------------------------------------------------------------------- 
    294 */ 
     291*/ 
     292} 
     293//--------------------------------------------------------------------------- 
     294