TrecApps / AnaGame

0 stars 1 forks source link

Need for dedicated Tab-bar and tabs #7

Closed TrecApps closed 3 years ago

TrecApps commented 4 years ago

Currently, there are two implementations of "Tabs" in Anagame:

  1. Anaface's AnafaceUI which uses a TLayoutEx to hold TControl's as "tabs"
  2. Tap's IDEPage has the IDEPageHolder to manage child pages and allows them to be moved around the window

Of the two, the second is more advanced as it was written recently (late 2019-early 2020) while the former was written either in 2017 or 2018. Therefore, the second Implementation has features absent in the first, such as:

Goal: Export this functionality into a dedicated Tab Bar Class and (possible Tab Class)

Tabs come in multiple styles and flavors and Anagame only supports basic text (and a fixed width in the case of the AnafaceUI class). Because there are two unique scenarios where tabs are used (and I don't want to declare that were won't be a third scenario) and that some functionality in the IDEPage tabs should also be present in the AnafaceUI implementation.

As a result, the functionality should be exported to a dedicated TabBar class in Anaface and should support the following features:

Security: Dragging support should be disabled in the AnafaceUI. The reason for this is if a control with an event is placed under a new Page, then it's likely that second page will have a different handler type than the previous one. As a result, the Control would end up sending the event to the wrong Handler and the wrong event handler will run.

Pull Requests made for this issue should be directed to the tabs branch