Commit b3c41d79 authored by Olivier Teulière's avatar Olivier Teulière

The win32 interface is preparing for the internationalization.

parent 5e1d56ae
...@@ -6,7 +6,7 @@ win32_CUSTOM = yes ...@@ -6,7 +6,7 @@ win32_CUSTOM = yes
win32.so: Makefile win32.so: Makefile
rm -f win32.mak rm -f win32.mak
$(BCBUILDER)/Bin/bpr2mak win32.bpr -s | sed 's#^LIBPATH = .*#&;$$(RELEASELIBPATH)# ; s#^USERDEFINES = .*#& -DWIN32 -D__PLUGIN__ -D__VLC__ -DMODULE_NAME_IS_win32 -DMODULE_NAME=win32 -DMODULE_PATH=modules_gui_win32_win32#' > win32.mak $(BCBUILDER)/Bin/bpr2mak win32.bpr -s | sed 's#^LIBPATH = .*#&;$$(RELEASELIBPATH)# ; s#^USERDEFINES = .*#& -DMODULE_NAME=win32 -DMODULE_PATH=modules_gui_win32_win32#' > win32.mak
$(BCBUILDER)/Bin/make -f win32.mak -b $(BCBUILDER)/Bin/make -f win32.mak -b
/***************************************************************************** /*****************************************************************************
* about.cpp: The "About" dialog box * about.cpp: The "About" dialog box
***************************************************************************** *****************************************************************************
* Copyright (C) 2002 VideoLAN * Copyright (C) 2002 VideoLAN
* *
* Authors: Olivier Teuliere <ipkiss@via.ecp.fr> * Authors: Olivier Teuliere <ipkiss@via.ecp.fr>
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
* *
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/ *****************************************************************************/
#include <vcl.h> #include <vcl.h>
#pragma hdrstop #pragma hdrstop
#include <vlc/vlc.h> #include <vlc/vlc.h>
#include <vlc/intf.h> #include <vlc/intf.h>
#include "about.h" #include "about.h"
#include "win32_common.h" #include "misc.h"
#include "win32_common.h"
//---------------------------------------------------------------------------
//#pragma package(smart_init) //---------------------------------------------------------------------------
#pragma resource "*.dfm" //#pragma package(smart_init)
#pragma resource "*.dfm"
extern intf_thread_t *p_intfGlobal;
extern intf_thread_t *p_intfGlobal;
//---------------------------------------------------------------------------
__fastcall TAboutDlg::TAboutDlg( TComponent* Owner ) //---------------------------------------------------------------------------
: TForm( Owner ) __fastcall TAboutDlg::TAboutDlg( TComponent* Owner )
{ : TForm( Owner )
Image1->Picture->Icon = p_intfGlobal->p_sys->p_window->Icon; {
LabelVersion->Caption = "Version " VERSION; Image1->Picture->Icon = p_intfGlobal->p_sys->p_window->Icon;
} LabelVersion->Caption = "Version " VERSION;
//--------------------------------------------------------------------------- Translate( this );
}
//---------------------------------------------------------------------------
...@@ -246,6 +246,7 @@ object AboutDlg: TAboutDlg ...@@ -246,6 +246,7 @@ object AboutDlg: TAboutDlg
PixelsPerInch = 96 PixelsPerInch = 96
TextHeight = 13 TextHeight = 13
object Label1: TLabel object Label1: TLabel
Tag = 3
Left = 114 Left = 114
Top = 18 Top = 18
Width = 132 Width = 132
...@@ -259,6 +260,7 @@ object AboutDlg: TAboutDlg ...@@ -259,6 +260,7 @@ object AboutDlg: TAboutDlg
ParentFont = False ParentFont = False
end end
object Label2: TLabel object Label2: TLabel
Tag = 3
Left = 10 Left = 10
Top = 64 Top = 64
Width = 267 Width = 267
...@@ -266,6 +268,7 @@ object AboutDlg: TAboutDlg ...@@ -266,6 +268,7 @@ object AboutDlg: TAboutDlg
Caption = '(C) Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002' Caption = '(C) Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002'
end end
object Label4: TLabel object Label4: TLabel
Tag = 3
Left = 15 Left = 15
Top = 123 Top = 123
Width = 253 Width = 253
...@@ -277,6 +280,7 @@ object AboutDlg: TAboutDlg ...@@ -277,6 +280,7 @@ object AboutDlg: TAboutDlg
WordWrap = True WordWrap = True
end end
object Label3: TLabel object Label3: TLabel
Tag = 3
Left = 30 Left = 30
Top = 80 Top = 80
Width = 227 Width = 227
...@@ -290,6 +294,7 @@ object AboutDlg: TAboutDlg ...@@ -290,6 +294,7 @@ object AboutDlg: TAboutDlg
Height = 49 Height = 49
end end
object Label5: TLabel object Label5: TLabel
Tag = 3
Left = 83 Left = 83
Top = 96 Top = 96
Width = 121 Width = 121
...@@ -297,6 +302,7 @@ object AboutDlg: TAboutDlg ...@@ -297,6 +302,7 @@ object AboutDlg: TAboutDlg
Caption = 'http://www.videolan.org/' Caption = 'http://www.videolan.org/'
end end
object LabelVersion: TLabel object LabelVersion: TLabel
Tag = 3
Left = 114 Left = 114
Top = 40 Top = 40
Width = 59 Width = 59
...@@ -304,6 +310,7 @@ object AboutDlg: TAboutDlg ...@@ -304,6 +310,7 @@ object AboutDlg: TAboutDlg
Caption = 'Version x.y.z' Caption = 'Version x.y.z'
end end
object BitBtnOk: TBitBtn object BitBtnOk: TBitBtn
Tag = 3
Left = 64 Left = 64
Top = 178 Top = 178
Width = 145 Width = 145
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
#include <vlc/intf.h> #include <vlc/intf.h>
#include "disc.h" #include "disc.h"
#include "misc.h";
#include "win32_common.h" #include "win32_common.h"
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
...@@ -42,6 +43,7 @@ __fastcall TDiscDlg::TDiscDlg( TComponent* Owner ) ...@@ -42,6 +43,7 @@ __fastcall TDiscDlg::TDiscDlg( TComponent* Owner )
{ {
/* Simulate a click to get the correct device name */ /* Simulate a click to get the correct device name */
RadioGroupTypeClick( RadioGroupType ); RadioGroupTypeClick( RadioGroupType );
Translate( this );
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
void __fastcall TDiscDlg::FormShow( TObject *Sender ) void __fastcall TDiscDlg::FormShow( TObject *Sender )
......
...@@ -248,6 +248,7 @@ object DiscDlg: TDiscDlg ...@@ -248,6 +248,7 @@ object DiscDlg: TDiscDlg
PixelsPerInch = 96 PixelsPerInch = 96
TextHeight = 13 TextHeight = 13
object LabelDevice: TLabel object LabelDevice: TLabel
Tag = 3
Left = 8 Left = 8
Top = 105 Top = 105
Width = 63 Width = 63
...@@ -255,6 +256,7 @@ object DiscDlg: TDiscDlg ...@@ -255,6 +256,7 @@ object DiscDlg: TDiscDlg
Caption = 'Device name' Caption = 'Device name'
end end
object GroupBoxPosition: TGroupBox object GroupBoxPosition: TGroupBox
Tag = 3
Left = 96 Left = 96
Top = 8 Top = 8
Width = 153 Width = 153
...@@ -262,6 +264,7 @@ object DiscDlg: TDiscDlg ...@@ -262,6 +264,7 @@ object DiscDlg: TDiscDlg
Caption = 'Starting position' Caption = 'Starting position'
TabOrder = 1 TabOrder = 1
object LabelTitle: TLabel object LabelTitle: TLabel
Tag = 3
Left = 16 Left = 16
Top = 24 Top = 24
Width = 20 Width = 20
...@@ -269,6 +272,7 @@ object DiscDlg: TDiscDlg ...@@ -269,6 +272,7 @@ object DiscDlg: TDiscDlg
Caption = 'Title' Caption = 'Title'
end end
object LabelChapter: TLabel object LabelChapter: TLabel
Tag = 3
Left = 16 Left = 16
Top = 52 Top = 52
Width = 37 Width = 37
...@@ -301,6 +305,7 @@ object DiscDlg: TDiscDlg ...@@ -301,6 +305,7 @@ object DiscDlg: TDiscDlg
end end
end end
object RadioGroupType: TRadioGroup object RadioGroupType: TRadioGroup
Tag = 3
Left = 8 Left = 8
Top = 8 Top = 8
Width = 81 Width = 81
...@@ -314,6 +319,7 @@ object DiscDlg: TDiscDlg ...@@ -314,6 +319,7 @@ object DiscDlg: TDiscDlg
OnClick = RadioGroupTypeClick OnClick = RadioGroupTypeClick
end end
object BitBtnOk: TBitBtn object BitBtnOk: TBitBtn
Tag = 3
Left = 8 Left = 8
Top = 136 Top = 136
Width = 113 Width = 113
...@@ -325,6 +331,7 @@ object DiscDlg: TDiscDlg ...@@ -325,6 +331,7 @@ object DiscDlg: TDiscDlg
OnClick = BitBtnOkClick OnClick = BitBtnOkClick
end end
object BitBtnCancel: TBitBtn object BitBtnCancel: TBitBtn
Tag = 3
Left = 136 Left = 136
Top = 136 Top = 136
Width = 113 Width = 113
...@@ -335,6 +342,7 @@ object DiscDlg: TDiscDlg ...@@ -335,6 +342,7 @@ object DiscDlg: TDiscDlg
OnClick = BitBtnCancelClick OnClick = BitBtnCancelClick
end end
object EditDevice: TEdit object EditDevice: TEdit
Tag = 5
Left = 88 Left = 88
Top = 101 Top = 101
Width = 161 Width = 161
......
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
#include "preferences.h" #include "preferences.h"
#include "messages.h" #include "messages.h"
#include "playlist.h" #include "playlist.h"
#include "misc.h"
#include "win32_common.h" #include "win32_common.h"
#include "netutils.h" #include "netutils.h"
...@@ -64,6 +65,8 @@ __fastcall TMainFrameDlg::TMainFrameDlg( TComponent* Owner ) ...@@ -64,6 +65,8 @@ __fastcall TMainFrameDlg::TMainFrameDlg( TComponent* Owner )
Caption = VOUT_TITLE " (Win32 interface)"; Caption = VOUT_TITLE " (Win32 interface)";
StringListPref = new TStringList(); StringListPref = new TStringList();
Translate( this );
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
__fastcall TMainFrameDlg::~TMainFrameDlg() __fastcall TMainFrameDlg::~TMainFrameDlg()
......
object MainFrameDlg: TMainFrameDlg object MainFrameDlg: TMainFrameDlg
Left = 179 Left = 285
Top = 442 Top = 170
Width = 541 Width = 541
Height = 306 Height = 306
BorderIcons = [biSystemMenu, biMinimize] BorderIcons = [biSystemMenu, biMinimize]
...@@ -151,16 +151,19 @@ object MainFrameDlg: TMainFrameDlg ...@@ -151,16 +151,19 @@ object MainFrameDlg: TMainFrameDlg
ShowCaptions = True ShowCaptions = True
TabOrder = 0 TabOrder = 0
object ToolButtonFile: TToolButton object ToolButtonFile: TToolButton
Tag = 3
Left = 0 Left = 0
Top = 0 Top = 0
Action = OpenFileAction Action = OpenFileAction
end end
object ToolButtonDisc: TToolButton object ToolButtonDisc: TToolButton
Tag = 3
Left = 39 Left = 39
Top = 0 Top = 0
Action = OpenDiscAction Action = OpenDiscAction
end end
object ToolButtonNet: TToolButton object ToolButtonNet: TToolButton
Tag = 3
Left = 78 Left = 78
Top = 0 Top = 0
Action = NetworkStreamAction Action = NetworkStreamAction
...@@ -174,26 +177,31 @@ object MainFrameDlg: TMainFrameDlg ...@@ -174,26 +177,31 @@ object MainFrameDlg: TMainFrameDlg
Style = tbsSeparator Style = tbsSeparator
end end
object ToolButtonBack: TToolButton object ToolButtonBack: TToolButton
Tag = 3
Left = 125 Left = 125
Top = 0 Top = 0
Action = BackAction Action = BackAction
end end
object ToolButtonPlay: TToolButton object ToolButtonPlay: TToolButton
Tag = 3
Left = 164 Left = 164
Top = 0 Top = 0
Action = PlayAction Action = PlayAction
end end
object ToolButtonPause: TToolButton object ToolButtonPause: TToolButton
Tag = 3
Left = 203 Left = 203
Top = 0 Top = 0
Action = PauseAction Action = PauseAction
end end
object ToolButtonStop: TToolButton object ToolButtonStop: TToolButton
Tag = 3
Left = 242 Left = 242
Top = 0 Top = 0
Action = StopAction Action = StopAction
end end
object ToolButtonEject: TToolButton object ToolButtonEject: TToolButton
Tag = 3
Left = 281 Left = 281
Top = 0 Top = 0
Action = EjectAction Action = EjectAction
...@@ -207,11 +215,13 @@ object MainFrameDlg: TMainFrameDlg ...@@ -207,11 +215,13 @@ object MainFrameDlg: TMainFrameDlg
Style = tbsSeparator Style = tbsSeparator
end end
object ToolButtonSlow: TToolButton object ToolButtonSlow: TToolButton
Tag = 3
Left = 328 Left = 328
Top = 0 Top = 0
Action = SlowAction Action = SlowAction
end end
object ToolButtonFast: TToolButton object ToolButtonFast: TToolButton
Tag = 3
Left = 367 Left = 367
Top = 0 Top = 0
Action = FastAction Action = FastAction
...@@ -225,17 +235,20 @@ object MainFrameDlg: TMainFrameDlg ...@@ -225,17 +235,20 @@ object MainFrameDlg: TMainFrameDlg
Style = tbsSeparator Style = tbsSeparator
end end
object ToolButtonPlaylist: TToolButton object ToolButtonPlaylist: TToolButton
Tag = 3
Left = 414 Left = 414
Top = 0 Top = 0
Action = PlaylistAction Action = PlaylistAction
Style = tbsCheck Style = tbsCheck
end end
object ToolButtonPrev: TToolButton object ToolButtonPrev: TToolButton
Tag = 3
Left = 453 Left = 453
Top = 0 Top = 0
Action = PreviousAction Action = PreviousAction
end end
object ToolButtonNext: TToolButton object ToolButtonNext: TToolButton
Tag = 3
Left = 492 Left = 492
Top = 0 Top = 0
Action = NextAction Action = NextAction
...@@ -252,6 +265,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -252,6 +265,7 @@ object MainFrameDlg: TMainFrameDlg
SimplePanel = True SimplePanel = True
end end
object GroupBoxFile: TGroupBox object GroupBoxFile: TGroupBox
Tag = 3
Left = 0 Left = 0
Top = 90 Top = 90
Width = 533 Width = 533
...@@ -260,6 +274,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -260,6 +274,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 2 TabOrder = 2
Visible = False Visible = False
object LabelFileName: TLabel object LabelFileName: TLabel
Tag = 3
Left = 2 Left = 2
Top = 15 Top = 15
Width = 529 Width = 529
...@@ -278,6 +293,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -278,6 +293,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 3 TabOrder = 3
Visible = False Visible = False
object LabelChannel: TLabel object LabelChannel: TLabel
Tag = 3
Left = 288 Left = 288
Top = 16 Top = 16
Width = 42 Width = 42
...@@ -285,6 +301,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -285,6 +301,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = 'Channel:' Caption = 'Channel:'
end end
object LabelServer: TLabel object LabelServer: TLabel
Tag = 3
Left = 64 Left = 64
Top = 16 Top = 16
Width = 49 Width = 49
...@@ -292,6 +309,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -292,6 +309,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = 'No server!' Caption = 'No server!'
end end
object ButtonGo: TButton object ButtonGo: TButton
Tag = 3
Left = 384 Left = 384
Top = 10 Top = 10
Width = 25 Width = 25
...@@ -320,6 +338,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -320,6 +338,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 4 TabOrder = 4
Visible = False Visible = False
object LabelDisc: TLabel object LabelDisc: TLabel
Tag = 3
Left = 32 Left = 32
Top = 11 Top = 11
Width = 21 Width = 21
...@@ -327,6 +346,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -327,6 +346,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = 'Disc' Caption = 'Disc'
end end
object LabelTitle: TLabel object LabelTitle: TLabel
Tag = 3
Left = 96 Left = 96
Top = 11 Top = 11
Width = 23 Width = 23
...@@ -334,6 +354,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -334,6 +354,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = 'Title:' Caption = 'Title:'
end end
object LabelChapter: TLabel object LabelChapter: TLabel
Tag = 3
Left = 296 Left = 296
Top = 11 Top = 11
Width = 40 Width = 40
...@@ -355,6 +376,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -355,6 +376,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = '---' Caption = '---'
end end
object ButtonTitlePrev: TButton object ButtonTitlePrev: TButton
Tag = 3
Left = 152 Left = 152
Top = 8 Top = 8
Width = 33 Width = 33
...@@ -363,6 +385,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -363,6 +385,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 0 TabOrder = 0
end end
object ButtonTitleNext: TButton object ButtonTitleNext: TButton
Tag = 3
Left = 184 Left = 184
Top = 8 Top = 8
Width = 33 Width = 33
...@@ -371,6 +394,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -371,6 +394,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 1 TabOrder = 1
end end
object ButtonChapterPrev: TButton object ButtonChapterPrev: TButton
Tag = 3
Left = 368 Left = 368
Top = 8 Top = 8
Width = 33 Width = 33
...@@ -379,6 +403,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -379,6 +403,7 @@ object MainFrameDlg: TMainFrameDlg
TabOrder = 2 TabOrder = 2
end end
object ButtonChapterNext: TButton object ButtonChapterNext: TButton
Tag = 3
Left = 400 Left = 400
Top = 8 Top = 8
Width = 33 Width = 33
...@@ -388,6 +413,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -388,6 +413,7 @@ object MainFrameDlg: TMainFrameDlg
end end
end end
object GroupBoxSlider: TGroupBox object GroupBoxSlider: TGroupBox
Tag = 3
Left = 0 Left = 0
Top = 50 Top = 50
Width = 533 Width = 533
...@@ -417,16 +443,20 @@ object MainFrameDlg: TMainFrameDlg ...@@ -417,16 +443,20 @@ object MainFrameDlg: TMainFrameDlg
Left = 40 Left = 40
Top = 208 Top = 208
object MenuFile: TMenuItem object MenuFile: TMenuItem
Tag = 3
Caption = '&File' Caption = '&File'
object MenuOpenFile: TMenuItem object MenuOpenFile: TMenuItem
Tag = 3
Action = OpenFileAction Action = OpenFileAction
Caption = 'Open &file...' Caption = 'Open &file...'
end end
object MenuOpenDisc: TMenuItem object MenuOpenDisc: TMenuItem
Tag = 3
Action = OpenDiscAction Action = OpenDiscAction
Caption = 'Open &disc...' Caption = 'Open &disc...'
end end
object MenuNetworkStream: TMenuItem object MenuNetworkStream: TMenuItem
Tag = 3
Action = NetworkStreamAction Action = NetworkStreamAction
Caption = '&Network stream...' Caption = '&Network stream...'
end end
...@@ -435,6 +465,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -435,6 +465,7 @@ object MainFrameDlg: TMainFrameDlg
Visible = False Visible = False
end end
object MenuEjectDisc: TMenuItem object MenuEjectDisc: TMenuItem
Tag = 3
Action = EjectAction Action = EjectAction
Caption = '&Eject disc' Caption = '&Eject disc'
end end
...@@ -442,38 +473,46 @@ object MainFrameDlg: TMainFrameDlg ...@@ -442,38 +473,46 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object MenuExit: TMenuItem object MenuExit: TMenuItem
Tag = 3
Action = ExitAction Action = ExitAction
end end
end end
object MenuView: TMenuItem object MenuView: TMenuItem
Tag = 3
Caption = '&View' Caption = '&View'
object MenuHideinterface: TMenuItem object MenuHideinterface: TMenuItem
Tag = 3
Caption = '&Hide interface' Caption = '&Hide interface'
Hint = 'Hide the main interface window' Hint = 'Hide the main interface window'
OnClick = MenuHideinterfaceClick OnClick = MenuHideinterfaceClick
end end
object MenuFullscreen: TMenuItem object MenuFullscreen: TMenuItem
Tag = 3
Action = FullscreenAction Action = FullscreenAction
end end
object N2: TMenuItem object N2: TMenuItem
Caption = '-' Caption = '-'
end end
object MenuProgram: TMenuItem object MenuProgram: TMenuItem
Tag = 3
Caption = 'Progr&am' Caption = 'Progr&am'
Enabled = False Enabled = False
Hint = 'Select program' Hint = 'Select program'
end end
object MenuTitle: TMenuItem object MenuTitle: TMenuItem
Tag = 3
Caption = '&Title' Caption = '&Title'
Enabled = False Enabled = False
Hint = 'Select title' Hint = 'Select title'
end end
object MenuChapter: TMenuItem object MenuChapter: TMenuItem
Tag = 3
Caption = '&Chapter' Caption = '&Chapter'
Enabled = False Enabled = False
Hint = 'Select chapter' Hint = 'Select chapter'
end end
object MenuAngle: TMenuItem object MenuAngle: TMenuItem
Tag = 3
Caption = 'An&gle' Caption = 'An&gle'
Enabled = False Enabled = False
Hint = 'Select angle' Hint = 'Select angle'
...@@ -482,21 +521,26 @@ object MainFrameDlg: TMainFrameDlg ...@@ -482,21 +521,26 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object MenuPlaylist: TMenuItem object MenuPlaylist: TMenuItem
Tag = 3
Action = PlaylistAction Action = PlaylistAction
Caption = '&Playlist...' Caption = '&Playlist...'
end end
object MenuMessages: TMenuItem object MenuMessages: TMenuItem
Tag = 3
Action = MessagesAction Action = MessagesAction
end end
end end
object MenuSettings: TMenuItem object MenuSettings: TMenuItem
Tag = 3
Caption = '&Settings' Caption = '&Settings'
object MenuAudio: TMenuItem object MenuAudio: TMenuItem
Tag = 3
Caption = '&Audio' Caption = '&Audio'
Enabled = False Enabled = False
Hint = 'Select audio language' Hint = 'Select audio language'
end end
object MenuSubtitles: TMenuItem object MenuSubtitles: TMenuItem
Tag = 3
Caption = '&Subtitles' Caption = '&Subtitles'
Enabled = False Enabled = False
Hint = 'Select subtitles language' Hint = 'Select subtitles language'
...@@ -505,12 +549,15 @@ object MainFrameDlg: TMainFrameDlg ...@@ -505,12 +549,15 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object MenuPreferences: TMenuItem object MenuPreferences: TMenuItem
Tag = 3
Action = PreferencesAction Action = PreferencesAction
end end
end end
object MenuHelp: TMenuItem object MenuHelp: TMenuItem
Tag = 3
Caption = '&Help' Caption = '&Help'
object MenuAbout: TMenuItem object MenuAbout: TMenuItem
Tag = 3
Action = AboutAction Action = AboutAction
end end
end end
...@@ -2254,10 +2301,12 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2254,10 +2301,12 @@ object MainFrameDlg: TMainFrameDlg
Left = 72 Left = 72
Top = 208 Top = 208
object PopupClose: TMenuItem object PopupClose: TMenuItem
Tag = 3
Caption = '&Close this popup' Caption = '&Close this popup'
OnClick = PopupCloseClick OnClick = PopupCloseClick
end end
object PopupToggleInterface: TMenuItem object PopupToggleInterface: TMenuItem
Tag = 3
Caption = '&Toggle interface' Caption = '&Toggle interface'
OnClick = PopupToggleInterfaceClick OnClick = PopupToggleInterfaceClick
end end
...@@ -2265,35 +2314,45 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2265,35 +2314,45 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object Control1: TMenuItem object Control1: TMenuItem
Tag = 3
Caption = 'Control' Caption = 'Control'
object PopupBack: TMenuItem object PopupBack: TMenuItem
Tag = 3
Action = BackAction Action = BackAction
end end
object PopupPlay: TMenuItem object PopupPlay: TMenuItem
Tag = 3
Action = PlayAction Action = PlayAction
end end
object PopupPause: TMenuItem object PopupPause: TMenuItem
Tag = 3
Action = PauseAction Action = PauseAction
end end
object PopupStop: TMenuItem object PopupStop: TMenuItem
Tag = 3
Action = StopAction Action = StopAction
end end
object PopupSlow: TMenuItem object PopupSlow: TMenuItem
Tag = 3
Action = SlowAction Action = SlowAction
end end
object PopupFast: TMenuItem object PopupFast: TMenuItem
Tag = 3
Action = FastAction Action = FastAction
end end
object N5: TMenuItem object N5: TMenuItem
Caption = '-' Caption = '-'
end end
object PopupPrev: TMenuItem object PopupPrev: TMenuItem
Tag = 3
Action = PreviousAction Action = PreviousAction
end end
object PopupNext: TMenuItem object PopupNext: TMenuItem
Tag = 3
Action = NextAction Action = NextAction
end end
object PopupJump: TMenuItem object PopupJump: TMenuItem
Tag = 3
Caption = '&Jump...' Caption = '&Jump...'
OnClick = PopupJumpClick OnClick = PopupJumpClick
end end
...@@ -2301,43 +2360,54 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2301,43 +2360,54 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object PopupFullscreen: TMenuItem object PopupFullscreen: TMenuItem
Tag = 3
Action = FullscreenAction Action = FullscreenAction
ShortCut = 70 ShortCut = 70
end end
end end
object PopupNavigation: TMenuItem object PopupNavigation: TMenuItem
Tag = 3
Caption = 'Navigation' Caption = 'Navigation'
end end
object PopupProgram: TMenuItem object PopupProgram: TMenuItem
Tag = 3
Caption = 'Program' Caption = 'Program'
end end
object PopupAudio: TMenuItem object PopupAudio: TMenuItem
Tag = 3
Caption = 'Audio' Caption = 'Audio'
end end
object PopupSubtitles: TMenuItem object PopupSubtitles: TMenuItem
Tag = 3
Caption = 'Subtitles' Caption = 'Subtitles'
end end
object N10: TMenuItem object N10: TMenuItem
Caption = '-' Caption = '-'
end end
object PopupPlaylist: TMenuItem object PopupPlaylist: TMenuItem
Tag = 3
Action = PlaylistAction Action = PlaylistAction
Caption = 'Playlist...' Caption = 'Playlist...'
end end
object PopupPreferences: TMenuItem object PopupPreferences: TMenuItem
Tag = 3
Action = PreferencesAction Action = PreferencesAction
end end
object PopupFile: TMenuItem object PopupFile: TMenuItem
Tag = 3
Caption = 'New stream' Caption = 'New stream'
object PopupOpenFile: TMenuItem object PopupOpenFile: TMenuItem
Tag = 3
Action = OpenFileAction Action = OpenFileAction
Caption = 'Open file...' Caption = 'Open file...'
end end
object PopupOpenDisc: TMenuItem object PopupOpenDisc: TMenuItem
Tag = 3
Action = OpenDiscAction Action = OpenDiscAction
Caption = 'Open disc...' Caption = 'Open disc...'
end end
object PopupNetworkStream: TMenuItem object PopupNetworkStream: TMenuItem
Tag = 3
Action = NetworkStreamAction Action = NetworkStreamAction
Caption = 'Network stream...' Caption = 'Network stream...'
end end
...@@ -2346,6 +2416,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2346,6 +2416,7 @@ object MainFrameDlg: TMainFrameDlg
Caption = '-' Caption = '-'
end end
object PopupExit: TMenuItem object PopupExit: TMenuItem
Tag = 3
Action = ExitAction Action = ExitAction
end end
end end
...@@ -2358,6 +2429,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2358,6 +2429,7 @@ object MainFrameDlg: TMainFrameDlg
Left = 168 Left = 168
Top = 208 Top = 208
object OpenFileAction: TAction object OpenFileAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'File' Caption = 'File'
Hint = 'Open a file' Hint = 'Open a file'
...@@ -2366,6 +2438,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2366,6 +2438,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = OpenFileActionExecute OnExecute = OpenFileActionExecute
end end
object OpenDiscAction: TAction object OpenDiscAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Disc' Caption = 'Disc'
Hint = 'Open a DVD or VCD' Hint = 'Open a DVD or VCD'
...@@ -2374,6 +2447,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2374,6 +2447,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = OpenDiscActionExecute OnExecute = OpenDiscActionExecute
end end
object NetworkStreamAction: TAction object NetworkStreamAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Net' Caption = 'Net'
Hint = 'Open a network stream' Hint = 'Open a network stream'
...@@ -2382,6 +2456,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2382,6 +2456,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = NetworkStreamActionExecute OnExecute = NetworkStreamActionExecute
end end
object BackAction: TAction object BackAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Back' Caption = 'Back'
Enabled = False Enabled = False
...@@ -2389,6 +2464,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2389,6 +2464,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = BackActionExecute OnExecute = BackActionExecute
end end
object PlayAction: TAction object PlayAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Play' Caption = 'Play'
Hint = 'Play stream' Hint = 'Play stream'
...@@ -2396,6 +2472,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2396,6 +2472,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = PlayActionExecute OnExecute = PlayActionExecute
end end
object PauseAction: TAction object PauseAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Pause' Caption = 'Pause'
Enabled = False Enabled = False
...@@ -2404,6 +2481,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2404,6 +2481,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = PauseActionExecute OnExecute = PauseActionExecute
end end
object StopAction: TAction object StopAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Stop' Caption = 'Stop'
Enabled = False Enabled = False
...@@ -2412,6 +2490,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2412,6 +2490,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = StopActionExecute OnExecute = StopActionExecute
end end
object EjectAction: TAction object EjectAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Eject' Caption = 'Eject'
Enabled = False Enabled = False
...@@ -2420,6 +2499,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2420,6 +2499,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = EjectActionExecute OnExecute = EjectActionExecute
end end
object SlowAction: TAction object SlowAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Slow' Caption = 'Slow'
Enabled = False Enabled = False
...@@ -2428,6 +2508,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2428,6 +2508,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = SlowActionExecute OnExecute = SlowActionExecute
end end
object FastAction: TAction object FastAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Fast' Caption = 'Fast'
Enabled = False Enabled = False
...@@ -2436,6 +2517,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2436,6 +2517,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = FastActionExecute OnExecute = FastActionExecute
end end
object PreviousAction: TAction object PreviousAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Prev' Caption = 'Prev'
Hint = 'Previous file' Hint = 'Previous file'
...@@ -2443,6 +2525,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2443,6 +2525,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = PreviousActionExecute OnExecute = PreviousActionExecute
end end
object NextAction: TAction object NextAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Next' Caption = 'Next'
Hint = 'Next file' Hint = 'Next file'
...@@ -2450,6 +2533,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2450,6 +2533,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = NextActionExecute OnExecute = NextActionExecute
end end
object PlaylistAction: TAction object PlaylistAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Playlist' Caption = 'Playlist'
Hint = 'Open the playlist window' Hint = 'Open the playlist window'
...@@ -2458,6 +2542,7 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2458,6 +2542,7 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = PlaylistActionExecute OnExecute = PlaylistActionExecute
end end
object ExitAction: TAction object ExitAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Exit' Caption = 'Exit'
Hint = 'Exit the program' Hint = 'Exit the program'
...@@ -2465,18 +2550,21 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2465,18 +2550,21 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = ExitActionExecute OnExecute = ExitActionExecute
end end
object FullscreenAction: TAction object FullscreenAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Fullscreen' Caption = 'Fullscreen'
Hint = 'Toggle fullscreen' Hint = 'Toggle fullscreen'
OnExecute = FullscreenActionExecute OnExecute = FullscreenActionExecute
end end
object PreferencesAction: TAction object PreferencesAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Preferences...' Caption = 'Preferences...'
Hint = 'Configure the application' Hint = 'Configure the application'
OnExecute = PreferencesActionExecute OnExecute = PreferencesActionExecute
end end
object MessagesAction: TAction object MessagesAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'Messages...' Caption = 'Messages...'
Hint = 'Open the messages window' Hint = 'Open the messages window'
...@@ -2484,30 +2572,35 @@ object MainFrameDlg: TMainFrameDlg ...@@ -2484,30 +2572,35 @@ object MainFrameDlg: TMainFrameDlg
OnExecute = MessagesActionExecute OnExecute = MessagesActionExecute
end end
object AboutAction: TAction object AboutAction: TAction
Tag = 3
Category = 'Menu' Category = 'Menu'
Caption = 'About...' Caption = 'About...'
Hint = 'About this application' Hint = 'About this application'
OnExecute = AboutActionExecute OnExecute = AboutActionExecute
end end
object PrevTitleAction: TAction object PrevTitleAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Prev' Caption = 'Prev'
Hint = 'Jump to previous title' Hint = 'Jump to previous title'
OnExecute = PrevTitleActionExecute OnExecute = PrevTitleActionExecute
end end
object NextTitleAction: TAction object NextTitleAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Next' Caption = 'Next'
Hint = 'Jump to next title' Hint = 'Jump to next title'
OnExecute = NextTitleActionExecute OnExecute = NextTitleActionExecute
end end
object PrevChapterAction: TAction object PrevChapterAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Prev' Caption = 'Prev'
Hint = 'Jump to previous chapter' Hint = 'Jump to previous chapter'
OnExecute = PrevChapterActionExecute OnExecute = PrevChapterActionExecute
end end
object NextChapterAction: TAction object NextChapterAction: TAction
Tag = 3
Category = 'Control' Category = 'Control'
Caption = 'Next' Caption = 'Next'
Hint = 'Jump to next chapter' Hint = 'Jump to next chapter'
......
...@@ -178,15 +178,15 @@ __published: // IDE-managed Components ...@@ -178,15 +178,15 @@ __published: // IDE-managed Components
void __fastcall StopActionExecute( TObject *Sender ); void __fastcall StopActionExecute( TObject *Sender );
void __fastcall SlowActionExecute( TObject *Sender ); void __fastcall SlowActionExecute( TObject *Sender );
void __fastcall FastActionExecute( TObject *Sender ); void __fastcall FastActionExecute( TObject *Sender );
void __fastcall EjectActionExecute( TObject *Sender );
void __fastcall PlaylistActionExecute( TObject *Sender ); void __fastcall PlaylistActionExecute( TObject *Sender );
void __fastcall ExitActionExecute( TObject *Sender );
void __fastcall PreviousActionExecute( TObject *Sender ); void __fastcall PreviousActionExecute( TObject *Sender );
void __fastcall NextActionExecute( TObject *Sender ); void __fastcall NextActionExecute( TObject *Sender );
void __fastcall FullscreenActionExecute( TObject *Sender ); void __fastcall FullscreenActionExecute( TObject *Sender );
void __fastcall PreferencesActionExecute( TObject *Sender ); void __fastcall PreferencesActionExecute( TObject *Sender );
void __fastcall MessagesActionExecute( TObject *Sender ); void __fastcall MessagesActionExecute( TObject *Sender );
void __fastcall AboutActionExecute( TObject *Sender ); void __fastcall AboutActionExecute( TObject *Sender );
void __fastcall EjectActionExecute( TObject *Sender ); void __fastcall ExitActionExecute( TObject *Sender );
void __fastcall PrevTitleActionExecute( TObject *Sender ); void __fastcall PrevTitleActionExecute( TObject *Sender );
void __fastcall NextTitleActionExecute( TObject *Sender ); void __fastcall NextTitleActionExecute( TObject *Sender );
void __fastcall PrevChapterActionExecute( TObject *Sender ); void __fastcall PrevChapterActionExecute( TObject *Sender );
......
...@@ -26,8 +26,9 @@ ...@@ -26,8 +26,9 @@
#include <vlc/vlc.h> #include <vlc/vlc.h>
#include <vlc/intf.h> #include <vlc/intf.h>
#include "win32_common.h"
#include "messages.h" #include "messages.h"
#include "misc.h"
#include "win32_common.h"
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
#pragma package(smart_init) #pragma package(smart_init)
...@@ -40,6 +41,7 @@ __fastcall TMessagesDlg::TMessagesDlg( TComponent* Owner ) ...@@ -40,6 +41,7 @@ __fastcall TMessagesDlg::TMessagesDlg( TComponent* Owner )
: TForm( Owner ) : TForm( Owner )
{ {
Icon = p_intfGlobal->p_sys->p_window->Icon; Icon = p_intfGlobal->p_sys->p_window->Icon;
Translate( this );
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
void __fastcall TMessagesDlg::ButtonOKClick( TObject *Sender ) void __fastcall TMessagesDlg::ButtonOKClick( TObject *Sender )
......
...@@ -34,6 +34,7 @@ object MessagesDlg: TMessagesDlg ...@@ -34,6 +34,7 @@ object MessagesDlg: TMessagesDlg
WantReturns = False WantReturns = False
end end
object ButtonOK: TButton object ButtonOK: TButton
Tag = 3
Left = 144 Left = 144
Top = 437 Top = 437
Width = 145 Width = 145
......
/*****************************************************************************
* misc.cpp: miscellaneous functions.
*****************************************************************************
* Copyright (C) 2002 VideoLAN
*
* Authors: Olivier Teuliere <ipkiss@via.ecp.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* 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., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/
#include <vcl.h>
#pragma hdrstop
#include "misc.h"
/****************************************************************************
* This function replaces "Hint", "Caption" and "Text" properties of each
* component of the form by the appropriate translation.
****************************************************************************/
void __fastcall Translate( TForm *Form )
{
#if 0
Form->Hint = N_( Form->Hint );
Form->Caption = N_( Form->Caption );
int i;
for( i = 0; i < Form->ComponentCount; i++ )
{
// Does this component need a translation ?
if( Form->Components[i]->Tag > 0 )
{
TComponent *Component = Form->Components[i];
// Hint property
if( Component->Tag & 1 )
{
if( Component->InheritsFrom( __classid( TControl ) ) )
{
TControl *Object = (TControl *) Component;
Object->Hint = N_( Object->Hint );
}
else if( Component->InheritsFrom( __classid( TMenuItem ) ) )
{
TMenuItem *Object = (TMenuItem *) Component;
Object->Hint = N_( Object->Hint );
}
}
// Caption property
if( Component->Tag & 2 )
{
if( Component->InheritsFrom( __classid( TMenuItem ) ) )
{
TMenuItem *Object = (TMenuItem *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TLabel ) ) )
{
TLabel *Object = (TLabel *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TButton ) ) )
{
TButton *Object = (TButton *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TToolButton ) ) )
{
TToolButton *Object = (TToolButton *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TRadioButton ) ) )
{
TRadioButton *Object = (TRadioButton *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TCheckBox ) ) )
{
TCheckBox *Object = (TCheckBox *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TRadioGroup ) ) )
{
TRadioGroup *Object = (TRadioGroup *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TGroupBox ) ) )
{
TGroupBox *Object = (TGroupBox *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TTabSheet ) ) )
{
TTabSheet *Object = (TTabSheet *) Component;
Object->Caption = N_( Object->Caption );
}
else if( Component->InheritsFrom( __classid( TListView ) ) )
{
TListView *Object = (TListView *) Component;
int iCol;
for( iCol = 0; iCol < Object->Columns->Count; iCol++ )
Object->Columns->Items[iCol]->Caption =
N_( Object->Columns->Items[iCol]->Caption );
}
}
// Text property
if( Component->Tag & 4 )
{
if( Component->InheritsFrom( __classid( TEdit ) ) )
{
TEdit *Object = (TEdit *) Component;
Object->Text = N_( Object->Text );
}
else if( Component->InheritsFrom( __classid( TComboBox ) ) )
{
TComboBox *Object = (TComboBox *) Component;
Object->Text = N_( Object->Text );
}
}
}
}
#endif
}
/*****************************************************************************
* misc.h: Prototype for main window
*****************************************************************************
* Copyright (C) 2002 VideoLAN
*
* Authors: Olivier Teuliere <ipkiss@via.ecp.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* 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., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/
#ifndef miscH
#define miscH
void __fastcall Translate( TForm *Form );
#endif
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
#include <vlc/intf.h> #include <vlc/intf.h>
#include "network.h" #include "network.h"
#include "misc.h"
#include "win32_common.h" #include "win32_common.h"
#include "netutils.h" #include "netutils.h"
...@@ -65,6 +66,8 @@ __fastcall TNetworkDlg::TNetworkDlg( TComponent* Owner ) ...@@ -65,6 +66,8 @@ __fastcall TNetworkDlg::TNetworkDlg( TComponent* Owner )
} }
SpinEditCSPort->Value = config_GetInt( p_intfGlobal, "channel-port" ); SpinEditCSPort->Value = config_GetInt( p_intfGlobal, "channel-port" );
Translate( this );
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
void __fastcall TNetworkDlg::FormShow( TObject *Sender ) void __fastcall TNetworkDlg::FormShow( TObject *Sender )
......
...@@ -248,6 +248,7 @@ object NetworkDlg: TNetworkDlg ...@@ -248,6 +248,7 @@ object NetworkDlg: TNetworkDlg
PixelsPerInch = 96 PixelsPerInch = 96
TextHeight = 13 TextHeight = 13
object BitBtnOk: TBitBtn object BitBtnOk: TBitBtn
Tag = 3
Left = 40 Left = 40
Top = 168 Top = 168
Width = 177 Width = 177
...@@ -257,6 +258,7 @@ object NetworkDlg: TNetworkDlg ...@@ -257,6 +258,7 @@ object NetworkDlg: TNetworkDlg
Kind = bkOK Kind = bkOK
end end
object BitBtnCancel: TBitBtn object BitBtnCancel: TBitBtn
Tag = 3
Left = 256 Left = 256
Top = 168 Top = 168
Width = 177 Width = 177
...@@ -266,6 +268,7 @@ object NetworkDlg: TNetworkDlg ...@@ -266,6 +268,7 @@ object NetworkDlg: TNetworkDlg
Kind = bkCancel Kind = bkCancel
end end
object GroupBoxMode: TGroupBox object GroupBoxMode: TGroupBox
Tag = 3
Left = 8 Left = 8
Top = 8 Top = 8
Width = 465 Width = 465
...@@ -273,6 +276,7 @@ object NetworkDlg: TNetworkDlg ...@@ -273,6 +276,7 @@ object NetworkDlg: TNetworkDlg
Caption = 'Network mode' Caption = 'Network mode'
TabOrder = 2 TabOrder = 2
object LabelUDPPort: TLabel object LabelUDPPort: TLabel
Tag = 3
Left = 148 Left = 148
Top = 26 Top = 26
Width = 22 Width = 22
...@@ -280,6 +284,7 @@ object NetworkDlg: TNetworkDlg ...@@ -280,6 +284,7 @@ object NetworkDlg: TNetworkDlg
Caption = 'Port:' Caption = 'Port:'
end end
object LabelMulticastPort: TLabel object LabelMulticastPort: TLabel
Tag = 3
Left = 364 Left = 364
Top = 54 Top = 54
Width = 22 Width = 22
...@@ -288,6 +293,7 @@ object NetworkDlg: TNetworkDlg ...@@ -288,6 +293,7 @@ object NetworkDlg: TNetworkDlg
Enabled = False Enabled = False
end end
object LabelCSPort: TLabel object LabelCSPort: TLabel
Tag = 3
Left = 364 Left = 364
Top = 82 Top = 82
Width = 22 Width = 22
...@@ -296,6 +302,7 @@ object NetworkDlg: TNetworkDlg ...@@ -296,6 +302,7 @@ object NetworkDlg: TNetworkDlg
Enabled = False Enabled = False
end end
object LabelMulticastAddress: TLabel object LabelMulticastAddress: TLabel
Tag = 3
Left = 139 Left = 139
Top = 54 Top = 54
Width = 41 Width = 41
...@@ -304,6 +311,7 @@ object NetworkDlg: TNetworkDlg ...@@ -304,6 +311,7 @@ object NetworkDlg: TNetworkDlg
Enabled = False Enabled = False
end end
object LabelCSAddress: TLabel object LabelCSAddress: TLabel
Tag = 3
Left = 139 Left = 139
Top = 82 Top = 82
Width = 41 Width = 41
...@@ -312,6 +320,7 @@ object NetworkDlg: TNetworkDlg ...@@ -312,6 +320,7 @@ object NetworkDlg: TNetworkDlg
Enabled = False Enabled = False
end end
object LabelHTTPURL: TLabel object LabelHTTPURL: TLabel
Tag = 3
Left = 147 Left = 147
Top = 110 Top = 110
Width = 25 Width = 25
...@@ -320,6 +329,7 @@ object NetworkDlg: TNetworkDlg ...@@ -320,6 +329,7 @@ object NetworkDlg: TNetworkDlg
Enabled = False Enabled = False
end end
object RadioButtonUDP: TRadioButton object RadioButtonUDP: TRadioButton
Tag = 3
Left = 16 Left = 16
Top = 24 Top = 24
Width = 97 Width = 97
...@@ -331,6 +341,7 @@ object NetworkDlg: TNetworkDlg ...@@ -331,6 +341,7 @@ object NetworkDlg: TNetworkDlg
OnEnter = RadioButtonUDPEnter OnEnter = RadioButtonUDPEnter
end end
object RadioButtonMulticast: TRadioButton object RadioButtonMulticast: TRadioButton
Tag = 3
Left = 16 Left = 16
Top = 52 Top = 52
Width = 97 Width = 97
...@@ -340,6 +351,7 @@ object NetworkDlg: TNetworkDlg ...@@ -340,6 +351,7 @@ object NetworkDlg: TNetworkDlg
OnEnter = RadioButtonMulticastEnter OnEnter = RadioButtonMulticastEnter
end end
object RadioButtonCS: TRadioButton object RadioButtonCS: TRadioButton
Tag = 3
Left = 16 Left = 16
Top = 80 Top = 80
Width = 97 Width = 97
...@@ -349,6 +361,7 @@ object NetworkDlg: TNetworkDlg ...@@ -349,6 +361,7 @@ object NetworkDlg: TNetworkDlg
OnEnter = RadioButtonCSEnter OnEnter = RadioButtonCSEnter
end end
object RadioButtonHTTP: TRadioButton object RadioButtonHTTP: TRadioButton
Tag = 3
Left = 16 Left = 16
Top = 108 Top = 108
Width = 97 Width = 97
...@@ -358,6 +371,7 @@ object NetworkDlg: TNetworkDlg ...@@ -358,6 +371,7 @@ object NetworkDlg: TNetworkDlg
OnEnter = RadioButtonHTTPEnter OnEnter = RadioButtonHTTPEnter
end end
object ComboBoxMulticastAddress: TComboBox object ComboBoxMulticastAddress: TComboBox
Tag = 5
Left = 184 Left = 184
Top = 50 Top = 50
Width = 161 Width = 161
...@@ -367,6 +381,7 @@ object NetworkDlg: TNetworkDlg ...@@ -367,6 +381,7 @@ object NetworkDlg: TNetworkDlg
TabOrder = 5 TabOrder = 5
end end
object ComboBoxCSAddress: TComboBox object ComboBoxCSAddress: TComboBox
Tag = 5
Left = 184 Left = 184
Top = 78 Top = 78
Width = 161 Width = 161
...@@ -379,6 +394,7 @@ object NetworkDlg: TNetworkDlg ...@@ -379,6 +394,7 @@ object NetworkDlg: TNetworkDlg
'vlcs') 'vlcs')
end end
object EditHTTPURL: TEdit object EditHTTPURL: TEdit
Tag = 5
Left = 184 Left = 184
Top = 106 Top = 106
Width = 265 Width = 265
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
#include <vlc/intf.h> #include <vlc/intf.h>
#include "playlist.h" #include "playlist.h"
#include "misc.h"
#include "win32_common.h" #include "win32_common.h"
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
...@@ -40,6 +41,7 @@ __fastcall TPlaylistDlg::TPlaylistDlg( TComponent* Owner ) ...@@ -40,6 +41,7 @@ __fastcall TPlaylistDlg::TPlaylistDlg( TComponent* Owner )
: TForm( Owner ) : TForm( Owner )
{ {
Icon = p_intfGlobal->p_sys->p_window->Icon; Icon = p_intfGlobal->p_sys->p_window->Icon;
Translate( this );
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
char * __fastcall TPlaylistDlg::rindex( char *s, char c ) char * __fastcall TPlaylistDlg::rindex( char *s, char c )
......
object PlaylistDlg: TPlaylistDlg object PlaylistDlg: TPlaylistDlg
Left = 162 Left = 346
Top = 364 Top = 231
Width = 335 Width = 335
Height = 436 Height = 436
Caption = 'Playlist' Caption = 'Playlist'
...@@ -17,6 +17,7 @@ object PlaylistDlg: TPlaylistDlg ...@@ -17,6 +17,7 @@ object PlaylistDlg: TPlaylistDlg
PixelsPerInch = 96 PixelsPerInch = 96
TextHeight = 13 TextHeight = 13
object BitBtnOk: TBitBtn object BitBtnOk: TBitBtn
Tag = 3
Left = 76 Left = 76
Top = 356 Top = 356
Width = 176 Width = 176
...@@ -28,6 +29,7 @@ object PlaylistDlg: TPlaylistDlg ...@@ -28,6 +29,7 @@ object PlaylistDlg: TPlaylistDlg
OnClick = BitBtnOkClick OnClick = BitBtnOkClick
end end
object ListViewPlaylist: TListView object ListViewPlaylist: TListView
Tag = 3
Left = 11 Left = 11
Top = 10 Top = 10
Width = 305 Width = 305
...@@ -58,41 +60,52 @@ object PlaylistDlg: TPlaylistDlg ...@@ -58,41 +60,52 @@ object PlaylistDlg: TPlaylistDlg
Left = 8 Left = 8
Top = 352 Top = 352
object MenuAdd: TMenuItem object MenuAdd: TMenuItem
Tag = 3
Caption = '&Add' Caption = '&Add'
object MenuAddFile: TMenuItem object MenuAddFile: TMenuItem
Tag = 3
Caption = '&File' Caption = '&File'
OnClick = MenuAddFileClick OnClick = MenuAddFileClick
end end
object MenuAddDisc: TMenuItem object MenuAddDisc: TMenuItem
Tag = 3
Caption = '&Disc' Caption = '&Disc'
OnClick = MenuAddDiscClick OnClick = MenuAddDiscClick
end end
object MenuAddNet: TMenuItem object MenuAddNet: TMenuItem
Tag = 3
Caption = '&Network' Caption = '&Network'
OnClick = MenuAddNetClick OnClick = MenuAddNetClick
end end
object MenuAddUrl: TMenuItem object MenuAddUrl: TMenuItem
Tag = 3
Caption = '&Url' Caption = '&Url'
Enabled = False Enabled = False
OnClick = MenuAddUrlClick OnClick = MenuAddUrlClick
end end
end end
object MenuDelete: TMenuItem object MenuDelete: TMenuItem
Tag = 3
Caption = '&Delete' Caption = '&Delete'
object MenuDeleteAll: TMenuItem object MenuDeleteAll: TMenuItem
Tag = 3
Action = DeleteAllAction Action = DeleteAllAction
end end
object MenuDeleteSelected: TMenuItem object MenuDeleteSelected: TMenuItem
Tag = 3
Action = DeleteSelectionAction Action = DeleteSelectionAction
Caption = '&Selection' Caption = '&Selection'
end end
end end
object MenuSelection: TMenuItem object MenuSelection: TMenuItem
Tag = 3
Caption = '&Selection' Caption = '&Selection'
object MenuSelectionCrop: TMenuItem object MenuSelectionCrop: TMenuItem
Tag = 3
Action = CropSelectionAction Action = CropSelectionAction
end end
object MenuSelectionInvert: TMenuItem object MenuSelectionInvert: TMenuItem
Tag = 3
Action = InvertSelectionAction Action = InvertSelectionAction
end end
end end
...@@ -101,16 +114,19 @@ object PlaylistDlg: TPlaylistDlg ...@@ -101,16 +114,19 @@ object PlaylistDlg: TPlaylistDlg
Left = 40 Left = 40
Top = 352 Top = 352
object PopupPlay: TMenuItem object PopupPlay: TMenuItem
Tag = 3
Action = PlayStreamAction Action = PlayStreamAction
end end
object N1: TMenuItem object N1: TMenuItem
Caption = '-' Caption = '-'
end end
object PopupInvertSelection: TMenuItem object PopupInvertSelection: TMenuItem
Tag = 3
Action = InvertSelectionAction Action = InvertSelectionAction
Caption = '&Invert selection' Caption = '&Invert selection'
end end
object PopupCropSelection: TMenuItem object PopupCropSelection: TMenuItem
Tag = 3
Action = CropSelectionAction Action = CropSelectionAction
Caption = '&Crop selection' Caption = '&Crop selection'
end end
...@@ -118,10 +134,12 @@ object PlaylistDlg: TPlaylistDlg ...@@ -118,10 +134,12 @@ object PlaylistDlg: TPlaylistDlg
Caption = '-' Caption = '-'
end end
object PopupDeleteSelected: TMenuItem object PopupDeleteSelected: TMenuItem
Tag = 3
Action = DeleteSelectionAction Action = DeleteSelectionAction
Caption = '&Delete selection' Caption = '&Delete selection'
end end
object PopupDeleteAll: TMenuItem object PopupDeleteAll: TMenuItem
Tag = 3
Action = DeleteAllAction Action = DeleteAllAction
Caption = 'Delete &all' Caption = 'Delete &all'
end end
...@@ -130,26 +148,31 @@ object PlaylistDlg: TPlaylistDlg ...@@ -130,26 +148,31 @@ object PlaylistDlg: TPlaylistDlg
Left = 264 Left = 264
Top = 352 Top = 352
object InvertSelectionAction: TAction object InvertSelectionAction: TAction
Tag = 3
Caption = 'Invert' Caption = 'Invert'
Hint = 'Invert selection' Hint = 'Invert selection'
OnExecute = InvertSelectionActionExecute OnExecute = InvertSelectionActionExecute
end end
object CropSelectionAction: TAction object CropSelectionAction: TAction
Tag = 3
Caption = 'Crop' Caption = 'Crop'
Hint = 'Crop selection' Hint = 'Crop selection'
OnExecute = CropSelectionActionExecute OnExecute = CropSelectionActionExecute
end end
object DeleteSelectionAction: TAction object DeleteSelectionAction: TAction
Tag = 3
Caption = 'Delete' Caption = 'Delete'
Hint = 'Delete selection' Hint = 'Delete selection'
OnExecute = DeleteSelectionActionExecute OnExecute = DeleteSelectionActionExecute
end end
object DeleteAllAction: TAction object DeleteAllAction: TAction
Tag = 3
Caption = 'All' Caption = 'All'
Hint = 'Delete all items' Hint = 'Delete all items'
OnExecute = DeleteAllActionExecute OnExecute = DeleteAllActionExecute
end end
object PlayStreamAction: TAction object PlayStreamAction: TAction
Tag = 3
Caption = 'Play' Caption = 'Play'
Hint = 'Play the selected stream' Hint = 'Play the selected stream'
OnExecute = PlayStreamActionExecute OnExecute = PlayStreamActionExecute
......
USEUNIT("win32.cpp"); USEUNIT("win32.cpp");
USEUNIT("intf_win32.cpp");
USEFORM("mainframe.cpp", MainFrameDlg); USEFORM("mainframe.cpp", MainFrameDlg);
USEFORM("network.cpp", NetworkDlg); USEFORM("network.cpp", NetworkDlg);
USEFORM("playlist.cpp", PlaylistDlg); USEFORM("playlist.cpp", PlaylistDlg);
...@@ -10,7 +9,8 @@ USEUNIT("control.cpp"); ...@@ -10,7 +9,8 @@ USEUNIT("control.cpp");
USE("win32_common.h", File); USE("win32_common.h", File);
USEUNIT("menu.cpp"); USEUNIT("menu.cpp");
USEFORM("messages.cpp", MessagesDlg); USEFORM("messages.cpp", MessagesDlg);
USEUNIT("misc.cpp");
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
This file is used by the project manager only and should be treated like the project file This file is used by the project manager only and should be treated like the project file
DllEntryPoint DllEntryPoint
\ No newline at end of file
......
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
<MACROS> <MACROS>
<VERSION value="BCB.05.03"/> <VERSION value="BCB.05.03"/>
<PROJECT value="win32.so"/> <PROJECT value="win32.so"/>
<OBJFILES value="win32.obj mainframe.obj network.obj playlist.obj <OBJFILES value="win32.obj mainframe.obj network.obj playlist.obj preferences.obj about.obj
preferences.obj about.obj disc.obj control.obj menu.obj messages.obj"/> disc.obj control.obj menu.obj messages.obj misc.obj"/>
<RESFILES value=""/> <RESFILES value=""/>
<DEFFILE value=""/> <DEFFILE value=""/>
<RESDEPEN value="$(RESFILES) mainframe.dfm network.dfm playlist.dfm preferences.dfm <RESDEPEN value="$(RESFILES) mainframe.dfm network.dfm playlist.dfm preferences.dfm
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
<DEBUGLIBPATH value="$(BCB)\lib\debug"/> <DEBUGLIBPATH value="$(BCB)\lib\debug"/>
<RELEASELIBPATH value="$(BCB)\lib\release"/> <RELEASELIBPATH value="$(BCB)\lib\release"/>
<LINKER value="tlink32"/> <LINKER value="tlink32"/>
<USERDEFINES value="_DEBUG"/> <USERDEFINES value="_DEBUG;WIN32;__VLC__;__PLUGIN__;MODULE_NAME_IS_win32"/>
<SYSDEFINES value="NO_STRICT"/> <SYSDEFINES value="NO_STRICT"/>
<MAINSOURCE value="win32.bpf"/> <MAINSOURCE value="win32.bpf"/>
<INCLUDEPATH value="..\..\win32;$(BCB)\include;$(BCB)\include\vcl;..\..\..\include;..\..\.."/> <INCLUDEPATH value="..\..\win32;$(BCB)\include;$(BCB)\include\vcl;..\..\..\include;..\..\.."/>
...@@ -72,20 +72,25 @@ ProductVersion=1.0.0.0 ...@@ -72,20 +72,25 @@ ProductVersion=1.0.0.0
Comments= Comments=
[HistoryLists\hlIncludePath] [HistoryLists\hlIncludePath]
Count1= Count=1
Item0=..\win32;..\..\win32;$(BCB)\include;$(BCB)\include\vcl;..\..\include;..\..\src\misc Item0=..\..\win32;$(BCB)\include;$(BCB)\include\vcl;..\..\..\include;..\..\src\misc
[HistoryLists\hlLibraryPath] [HistoryLists\hlLibraryPath]
Count=1 Count=2
Item0=..\win32;..\..\win32;$(BCB)\lib\obj;$(BCB)\lib Item0=..\..\win32;$(BCB)\lib\obj;$(BCB)\lib
Item1=..\win32;..\..\win32;$(BCB)\lib\obj;$(BCB)\lib
[HistoryLists\hlDebugSourcePath] [HistoryLists\hlDebugSourcePath]
Count=1 Count=1
Item0=$(BCB)\source\vcl Item0=$(BCB)\source\vcl
[HistoryLists\hlConditionals] [HistoryLists\hlConditionals]
Count=1 Count=5
Item0=_DEBUG Item0=_DEBUG;WIN32;__VLC__;__PLUGIN__;MODULE_NAME_IS_win32
Item1=_DEBUG;WIN32;__VLC__;__PLUGIN__;MODULE_NAME_IS_win32;MODULE_NAME=win32;MODULE_PATH=modules_gui_win32_win32
Item2=_DEBUG;__VLC__;__PLUGIN__;MODULE_NAME_IS_win32;MODULE_NAME=win32;MODULE_PATH=modules_gui_win32_win32
Item3=_DEBUG;__VLC__;__PLUGIN__
Item4=_DEBUG
[Debugging] [Debugging]
DebugSourceDirs=$(BCB)\source\vcl DebugSourceDirs=$(BCB)\source\vcl
...@@ -107,4 +112,4 @@ ActiveLang= ...@@ -107,4 +112,4 @@ ActiveLang=
ProjectLang= ProjectLang=
RootDir= RootDir=
</IDEOPTIONS> </IDEOPTIONS>
</PROJECT> </PROJECT>
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment