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 |
/** * Copyright 1998-2008 Epic Games, Inc. All Rights Reserved. * * Version of UTUITabPage_Options which allows you to add options at runtime, but which doesn't used ata providers */ Class UTUITabPage_DynamicOptions extends UTUITabPage_Options; var UTUIDynamicOptionList DynOptionList; function PostInitialize() { Super.PostInitialize(); if (OptionList != none) DynOptionList = UTUIDynamicOptionList(OptionList); } /** Callback for when an option is focused, by default tries to set the description label for this tab page. */ function OnOptionList_OptionFocused(UIScreenObject InObject, UIDataProvider OptionProvider) { local int i; i = DynOptionList.GetDynamicOptionIndexByObject(UIObject(InObject)); if (i != INDEX_None) DescriptionLabel.SetDataStoreBinding(DynOptionList.DynamicOptionTemplates[i].Description); OnOptionFocused(InObject, none); } /** Appends a keyboard button to the buttonbar if we are on PS3 and a editbox option is selected. */ function ConditionallyAppendKeyboardButton(UTUIButtonBar ButtonBar) { local UTUIScene UTScene; local int i; UTScene = UTUIScene(GetScene()); if (UTScene != none) { if (ISconsole(CONSOLE_PS3) && DynOptionList != none && OptionList.CurrentIndex >= 0 && OptionList.GeneratedObjects.Length > OptionList.CurrentIndex) { i = DynOptionList.GetDynamicOptionIndexByName(OptionList.GeneratedObjects[OptionList.CurrentIndex].OptionProviderName); if (i != INDEX_None && DynOptionList.DynamicOptionTemplates[i].OptionType == UTOT_EditBox) ButtonBar.AppendButton("<Strings:UTGameUI.ButtonCallouts.Keyboard>", OnButtonBar_ShowKeyboard); } } } /** Shows the onscreen keyboard using the currently selected option as a target. */ function OnShowKeyboard() { local int i; local UIEditBox EditboxObject; local string FriendlyName; i = DynOptionList.GetDynamicOptionIndexByName(OptionList.GeneratedObjects[OptionList.CurrentIndex].OptionProviderName); if (i != INDEX_None && DynOptionList.DynamicOptionTemplates[i].OptionType == UTOT_EditBox) { EditboxObject = UIEditBox(OptionList.GeneratedObjects[OptionList.CurrentIndex].OptionObj); FriendlyName = DynOptionList.DynamicOptionTemplates[i].FriendlyName; ShowKeyboard(EditboxObject, FriendlyName, FriendlyName, false, false, EditboxObject.GetValue(), EditboxObject.MaxCharacters); } } function OnResetToDefaults_Confirm(UTUIScene_MessageBox MessageBox, int SelectionIdx, int PlayerIndex); defaultproperties { 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_DynamicOptions" ObjectArchetype=UTUITabPage_Options'UTGame.Default__UTUITabPage_Options' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |