Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
00001 00002 00003 00004 00005 00006 00007 00008 00009 00010 00011 00012 00013 00014 00015 00016 00017 00018 00019 00020 00021 00022 00023 00024 00025 00026 00027 00028 00029 00030 00031 00032 00033 00034 00035 00036 00037 00038 00039 00040 00041 00042 00043 00044 00045 00046 00047 00048 00049 00050 00051 00052 00053 00054 00055 00056 00057 00058 00059 00060 00061 00062 00063 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 00084 00085 00086 00087 00088 00089 00090 00091 00092 00093 00094 00095 00096 00097 00098 00099 00100 00101 00102 00103 00104 00105 00106 00107 00108 00109 00110 |
/** * Copyright 1998-2008 Epic Games, Inc. All Rights Reserved. * * Tab page for a user's weapon settings. */ class UTUITabPage_WeaponSettings extends UTUITabPage_Options placeable; /** Reference to the weapon preference scene. */ var string WeaponPreferenceScene; /** Post initialization event - Setup widget delegates.*/ event PostInitialize() { Super.PostInitialize(); // Set the button tab caption. SetDataStoreBinding("<Strings:UTGameUI.Settings.Weapons>"); } /** Callback allowing the tabpage to setup the button bar for the current scene. */ function SetupButtonBar(UTUIButtonBar ButtonBar) { ButtonBar.AppendButton("<Strings:UTGameUI.ButtonCallouts.WeaponPreference>", OnButtonBar_WeaponPreference); ConditionallyAppendDefaultsButton(ButtonBar); } /** * Callback for when the weapon preference scene is opened. */ function OnShowWeaponPreferenceScene_Opened(UIScene OpenedScene, bool bInitialActivation) { if(OpenedScene != None) { UTUIFrontEnd_WeaponPreference(OpenedScene).MarkDirty = WeaponPreferencesChanged; } } /** Displays the key binding scene. */ function OnShowWeaponPreferenceScene() { UTUIScene(GetScene()).OpenSceneByName(WeaponPreferenceScene, false, OnShowWeaponPreferenceScene_Opened); } function WeaponPreferencesChanged() { // total hackery - kids, don't do this at home local UTUIFrontEnd_Settings SettingsScene; SettingsScene = UTUIFrontEnd_Settings(GetScene().GetPreviousScene()); if ( SettingsScene != None ) { SettingsScene.MarkDirty(); } } function bool OnButtonBar_WeaponPreference(UIScreenObject InButton, int PlayerIndex) { OnShowWeaponPreferenceScene(); return true; } /** * Provides a hook for unrealscript to respond to input using actual input key names (i.e. Left, Tab, etc.) * * Called when an input key event is received which this widget responds to and is in the correct state to process. The * keys and states widgets receive input for is managed through the UI editor's key binding dialog (F8). * * This delegate is called BEFORE kismet is given a chance to process the input. * * @param EventParms information about the input event. * * @return TRUE to indicate that this input key was processed; no further processing will occur on this input key event. */ function bool HandleInputKey( const out InputEventParameters EventParms ) { local bool bResult; bResult=false; if(EventParms.EventType==IE_Released) { if(EventParms.InputKeyName=='XboxTypeS_Y') { OnShowWeaponPreferenceScene(); bResult=true; } } return bResult; } defaultproperties { WeaponPreferenceScene="UI_Scenes_ChrisBLayout.Scenes.WeaponPreference" Begin Object Class=UIComp_Event Name=WidgetEventComponent ObjName=WidgetEventComponent Archetype=UIComp_Event'UTGame.Default__UTUITabPage_Options:WidgetEventComponent' ObjectArchetype=UIComp_Event'UTGame.Default__UTUITabPage_Options:WidgetEventComponent' End Object EventProvider=WidgetEventComponent Name="Default__UTUITabPage_WeaponSettings" ObjectArchetype=UTUITabPage_Options'UTGame.Default__UTUITabPage_Options' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |