Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
LayerQuickMenu Class Reference
Inheritance diagram for LayerQuickMenu:
ELayer Layer IUISkin

Public Member Functions

override void OnInit ()
 
override void OnUpdateInput ()
 
- Public Member Functions inherited from ELayer
override void OnBeforeAddLayer ()
 
void InitInspector ()
 
sealed override void Init ()
 
override void OnAfterAddLayer ()
 
void TryShowHelp ()
 
void AddLayerToUI (string id)
 
void TryShowHint (string _langHint=null)
 
void TalkHomeMemeber (string id)
 
void TalkMaid (string id)
 
override void OnRightClick ()
 
- Public Member Functions inherited from Layer
virtual string GetTextHeader (Window window)
 
virtual bool HeaderIsListOf (int id)
 
virtual void Init ()
 
virtual void OnInit ()
 
virtual void OnAfterInit ()
 
virtual void ApplySkin ()
 
void ShowScreenLock (string id)
 
void UpdateInput ()
 
virtual void OnUpdateInput ()
 
virtual void OnRightClick ()
 
virtual bool OnBack ()
 
virtual void OnChangeLayer ()
 
virtual void OnCreate ()
 
void _AddLayer (string id)
 
Layer AddLayer (string id)
 
AddLayer< T > ()
 
AddLayer< T > (string id)
 
AddLayerDontCloseOthers< T > ()
 
Layer AddLayerDontCloseOthers (Layer l)
 
GetOrAddLayer< T > ()
 
virtual void OnBeforeAddLayer ()
 
virtual void OnAfterAddLayer ()
 
Layer AddLayer (Layer l)
 
void ToggleLayer (string id)
 
ToggleLayer< T > (string id=null)
 
void WaitAndClose ()
 
void OnClickClose ()
 
virtual void Close ()
 
void CloseLayers ()
 
void RemoveLayers (bool removeImportant=false)
 
bool RemoveLayer< T > ()
 
void RemoveLayer (Layer l)
 
virtual void OnKill ()
 
Layer SetOnKill (Action action)
 
void DisableClose ()
 
void Delay (float duration=0.05f)
 
Layer SetDelay (float d)
 
Layer GetLayer (string id)
 
GetLayer< T > (bool fromTop=false)
 
Layer GetTopLayer ()
 
void SwitchContent (int idWindow, int i)
 
virtual void OnSwitchContent (Window window)
 
Layer SetTitles (string langList, string idHeaderRow=null)
 
bool IsBlockWidgetClick ()
 
bool IsHideHud ()
 
bool IsAllowGeneralInput ()
 
bool IsUseBlur ()
 
bool IsPointerOnLayer ()
 
void ApplySkin ()
 

Public Attributes

CircularRadialButton radial
 
Vector2 oriPos
 
float closeDist
 
- Public Attributes inherited from Layer
Option option
 
UnityEvent onKill
 
Anime animeIn
 
Anime animeOut
 
bool closeOthers
 
bool defaultActionMode = true
 
Button screenLock
 
Layer parent
 
string idLayer
 
List< Layerlayers = new List<Layer>()
 
Vector2 lastParentPos
 
List< Windowwindows = new List<Window>()
 
string langHint
 

Additional Inherited Members

- Static Public Member Functions inherited from ELayer
static int rnd (int a)
 
- Static Public Member Functions inherited from Layer
static T Create< T > ()
 
static T Create< T > (string path)
 
static Layer Create (string path)
 
- Static Public Attributes inherited from Layer
static int skipInput
 
static bool closeOnRightClick
 
static bool rightClicked
 
static bool cancelKeyDown
 
static bool ignoreSounds
 
static Transform blurStopInstance
 
static string[] searchPath = new string[3] { "Layer", "Layer/Dialog", "Layer/LayerHome" }
 
- Protected Member Functions inherited from ELayer
sealed override void _Close ()
 
sealed override void Kill ()
 
- Protected Member Functions inherited from Layer
virtual void Awake ()
 
virtual void _Close ()
 
virtual void Kill ()
 
- Protected Attributes inherited from Layer
RectTransform _rect
 
bool isDestroyed
 
- Properties inherited from ELayer
static Core core [get]
 
static Game game [get]
 
static bool AdvMode [get]
 
static Player player [get]
 
static Chara pc [get]
 
static FactionBranch Branch [get]
 
static Faction Home [get]
 
static UI ui [get]
 
static Map _map [get]
 
static Zone _zone [get]
 
static Scene scene [get]
 
static BaseGameScreen screen [get]
 
static CoreConfig config [get]
 
static GameSetting setting [get]
 
static ColorProfile Colors [get]
 
static SourceManager sources [get]
 
static World world [get]
 
static SoundManager Sound [get]
 
static CoreDebug debug [get]
 
bool IsFloat [get]
 
virtual string IdHelp [get]
 
- Properties inherited from Layer
Layer TopLayer [get]
 
string uid [get]
 
virtual RectTransform rectLayers [get]
 
virtual bool blockWidgetClick [get]
 

Detailed Description

Definition at line 3 of file LayerQuickMenu.cs.

Member Function Documentation

◆ OnInit()

override void LayerQuickMenu.OnInit ( )
inlinevirtual

Reimplemented from Layer.

Definition at line 11 of file LayerQuickMenu.cs.

12 {
13 QuickMenu quickMenu = new QuickMenu();
14 quickMenu.Build();
15 for (int i = 0; i < quickMenu.items.Count; i++)
16 {
17 QuickMenu.Item item = quickMenu.items[i];
18 UIButton uIButton = radial.AddOption(SpriteSheet.Get("icon_" + item.id), delegate
19 {
20 if (item.action != null)
21 {
22 item.action();
23 Close();
24 }
25 else
26 {
27 HotItemActionMode.Execute(item.id);
28 }
29 });
30 if (item.id.IsEmpty())
31 {
32 uIButton.icon.SetActive(enable: false);
33 uIButton.image.enabled = false;
34 }
35 else
36 {
37 uIButton.icon.enabled = uIButton.icon.sprite;
38 uIButton.tooltip.text = item.id.lang();
39 }
40 }
41 radial.transform.position = (oriPos = EInput.mpos);
42 radial.Init();
43 }
UIButton AddOption(Sprite sprite, Action action=null)
Definition: EInput.cs:8
static Vector3 mpos
Definition: EInput.cs:337
CircularRadialButton radial
List< Item > items
Definition: QuickMenu.cs:20
void Build()
Definition: QuickMenu.cs:22
static Sprite Get(string id)
Definition: SpriteSheet.cs:28
Image icon
Definition: UIButton.cs:110

References CircularRadialButton.AddOption(), QuickMenu.Build(), SpriteSheet.Get(), UIButton.icon, item, QuickMenu.items, and radial.

◆ OnUpdateInput()

override void LayerQuickMenu.OnUpdateInput ( )
inlinevirtual

Reimplemented from Layer.

Definition at line 45 of file LayerQuickMenu.cs.

46 {
47 if (Vector2.Distance(EInput.mpos, oriPos) > closeDist)
48 {
49 Close();
50 return;
51 }
52 if (Input.GetMouseButtonDown(0))
53 {
54 if (!InputModuleEX.IsPointerOver(base.transform))
55 {
56 Close();
57 return;
58 }
59 }
60 else if (!Application.isEditor && Input.anyKeyDown)
61 {
62 Close();
63 return;
64 }
66 }
static void ConsumeWheel()
Definition: EInput.cs:683
static bool IsPointerOver(Component c)
virtual void Close()
Definition: Layer.cs:463

References EInput.ConsumeWheel(), InputModuleEX.IsPointerOver(), and EInput.mpos.

Member Data Documentation

◆ closeDist

float LayerQuickMenu.closeDist

Definition at line 9 of file LayerQuickMenu.cs.

◆ oriPos

Vector2 LayerQuickMenu.oriPos

Definition at line 7 of file LayerQuickMenu.cs.

◆ radial

CircularRadialButton LayerQuickMenu.radial

Definition at line 5 of file LayerQuickMenu.cs.

Referenced by OnInit().


The documentation for this class was generated from the following file: