Ejemplo n.º 1
0
 public void Initialize(CalcManager cm)
 {
     calcManager = cm;
     keyboard    = GetComponent <FlexMenu>();
     responder   = new KeyboardInputResponder(this);
     keyboard.RegisterResponder(responder);
 }
Ejemplo n.º 2
0
 public void Initialize(PtManager2D pm)
 {
     ptManager2D = pm;
     keyboard    = GetComponent <FlexMenu>();
     responder   = new KeyboardInputResponder(this);
     keyboard.RegisterResponder(responder);
 }
Ejemplo n.º 3
0
    private void Initialize()
    {
        if (!initialized)
        {
            initialized = true;
            Instance    = this;

            ManageTournamentMenuResponder responder = new ManageTournamentMenuResponder(this);
            flexMenu  = GetComponent <FlexMenu>();
            mainPanel = GetComponentInChildren <FlexPanelComponent>();
            var btns = GetComponentsInChildren <FlexButtonComponent>(true);
            foreach (var button in btns)
            {
                mainPanel.AddAction(button);
                buttons.Add(button.gameObject.name, button);
            }
            var txts = GetComponentsInChildren <TMPro.TextMeshPro>(true);
            foreach (var txt in txts)
            {
                if (!text.ContainsKey(txt.gameObject.name))
                {
                    text.Add(txt.gameObject.name, txt);
                }
            }

            flexMenu.RegisterResponder(responder);
        }
    }
Ejemplo n.º 4
0
    public void Awake()
    {
        FlexMenu keyboard = GetComponent <FlexMenu>();
        KeyboardInputResponder responder = new KeyboardInputResponder(this);

        keyboard.RegisterResponder(responder);

        paramSurface = FindObjectOfType <CustomParametrizedSurface>();
    }
Ejemplo n.º 5
0
    public void Initialize(CalcManager calcManager)
    {
        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        SubmissionButtonResponder responder = new SubmissionButtonResponder(this, flexMenu);

        flexMenu.RegisterResponder(responder);
        submissionsPanel   = GetComponentInChildren <MultiSelectFlexPanel>().Initialize();
        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();
    }
Ejemplo n.º 6
0
    public void Initialize()
    {
        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        CommitButtonResponder responder = new CommitButtonResponder(this, flexMenu);

        flexMenu.RegisterResponder(responder);
        commitsPanel       = GetComponentInChildren <MultiSelectFlexPanel>().Initialize();
        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();
    }
Ejemplo n.º 7
0
    public void Initialize(CalcManager calcManager)
    {
        this.calcManager = calcManager;

        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        KeyboardInputResponder responder = new KeyboardInputResponder(this, flexMenu);

        flexMenu.RegisterResponder(responder);
        tournamentsPanel   = GetComponentInChildren <MultiSelectFlexPanel>().Initialize();
        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();
    }
Ejemplo n.º 8
0
    public void Initialize(CalcManager calcManager)
    {
        this.calcManager = calcManager;

        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        KeyboardInputResponder responder = new KeyboardInputResponder(this);

        flexMenu.RegisterResponder(responder);
        selectPanel        = GetComponentInChildren <MultiSelectFlexPanel>().Initialize();
        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();

        LoadFiles();
        loader.fileLoadedEvent += LoadNewFile;
    }
Ejemplo n.º 9
0
    public void Initialize()
    {
        if (Instance == null)
        {
            Instance = this;
        }

        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        AccountMenuResponder responder = new AccountMenuResponder(this, flexMenu);

        flexMenu.RegisterResponder(responder);
        accountsPanel = GetComponentInChildren <MultiSelectFlexPanel>(true);
        accountsPanel.Initialize();
        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();

        initialized = true;
    }
Ejemplo n.º 10
0
    public void Initialize(CalcManager calcManager)
    {
        this.calcManager = calcManager;

        scroll   = GetComponentInChildren <Scroll>(true);
        flexMenu = GetComponent <FlexMenu>();
        TournamentMenuResponder responder = new TournamentMenuResponder(this);

        submissionsPanel = GetComponentInChildren <MultiSelectFlexPanel>().Initialize();
        submissionsPanel.selectedUnselectedColor = QuickButton.TOGGLE_OFF;
        submissionsPanel.selectedSelectedColor   = QuickButton.TOGGLE_ON;
        submissionsPanel.hoverUnselectedColor    = QuickButton.LIGHT_HOVERING;
        submissionsPanel.hoverSelectedColor      = QuickButton.DARK_HOVERING;
        submissionsPanel.passiveUnselectedColor  = Color.white;
        submissionsPanel.passiveSelectedColor    = QuickButton.DARK_PASSIVE;

        joyStickAggregator = scroll.GetComponent <JoyStickAggregator>();

        mainPanel.AddAction(previousRoundButton);
        mainPanel.AddAction(nextRoundButton);
        flexMenu.AddPanel(mainPanel);
        flexMenu.RegisterResponder(responder);
    }
Ejemplo n.º 11
0
 public void SetMenu(FlexMenu menu)
 {
     this.menu = menu;
 }
Ejemplo n.º 12
0
 internal AccountMenuResponder(MyAccountMenu accountMenu, FlexMenu menu)
 {
     this.menu        = menu;
     this.accountMenu = accountMenu;
 }
Ejemplo n.º 13
0
 internal KeyboardInputResponder(TournamentMenu tournamentMenu, FlexMenu menu)
 {
     this.menu           = menu;
     this.tournamentMenu = tournamentMenu;
 }
Ejemplo n.º 14
0
 internal SubmissionButtonResponder(MySubmissionsMenu submissionsMenu, FlexMenu menu)
 {
     this.menu            = menu;
     this.submissionsMenu = submissionsMenu;
 }
Ejemplo n.º 15
0
 internal CommitButtonResponder(MyCommitsMenu myCommits, FlexMenu menu)
 {
     this.menu          = menu;
     this.myCommitsMenu = myCommits;
 }
Ejemplo n.º 16
0
 internal TournamentButtonResponder(TournamentsMenu tournamentMenu, FlexMenu menu)
 {
     this.menu           = menu;
     this.tournamentMenu = tournamentMenu;
 }