Commit Graph

22 Commits

Author SHA1 Message Date
BDisp
3e1637aac8 Fixes #2775. Something in 1.13 broke centering child windows. (#2778)
* Fixes #2776. Pressing Alt key on a Window with only a MenuBar throws System.InvalidOperationException.

* Add unit test.

* Fix extra bracket.

* Prevents throw exception if Application.Current is null.

* Fix unit test because OnLeave is now invoked on toplevel removing, preventing two views having focus.

* Fix unit test method name.

* Fix Window by not layout on his subviews when adding a new view after the Application.Begin was already running.

* FindAndOpenMenuByHotkey now search inside Menus and inside his Children.

* Add unit test for Window LayoutSubviews and FindAndOpenChildrenMenuByHotkey menu method.

* Prevents button to be clear when it's invisible.

* Fixes 2780. Moving a Window that is Application.Top shouldn't be allowed.

* Fix condition if Window and Application.Top.

* Always LayoutSubviews and PositionToplevels after Clear.

* Fixes #2787. MenuItem with CanExecute returning false is select when a MenuBar is opened.

* Leveraging the power of CanExecute feature.

* Fixes #2789. StatusItem should have a disabled attribute if it can't execute.

* Allows positioning a child window outside the limits of the menu and the status bar.

* Change to a more appropriate name.

* Simplifies all the run actions.

* Prevents open menu bar if it's invisible and close all opened menus.

* Fix mdi run loop.

* Fix hot key on mdi toplevels.

* Fix position on mdi toplevels.

* Fix Top.Redraw by set state.Toplevel.SetNeedsDisplay if it's needed to redraw.

* Fix MdiTop by repainted when a keystroke is generated by keyboard.

* Rename local fields.

* Force redraw if application.Top needs display.

* Added more features to the scenario.

* Change the scenarios to run as Application.Top instead of sub-views.

* Add a new scenario similar but as Mdi Container.

* Add a bunch of new unit tests to prove all this PR.

* Only it's need to redraw Application.Top if it's a Mdi Container.

* Remove unnecessary code.

* Unit test that proves that a MDI child leaves no trace when the location is changed.

* Removes unnecessary Application.Init because theses uses Run<T> which already call it.

* Ensures a menu bar been closed after run an action.

* Ensures that another view can be focused if not IsMenuOpen and LastFocused is null, instead of focused the menu itself.

* Ensures a focused contentview subview being focused if MostFocused is null.

* Ensures a MdiTop subview to have priority if it's focused and thus  make it Current.

* Allow a MdiChild be closed when pressing Application.QuitKey.

* More unit tests proving the changes.

* Ensures the top.MostFocused is focused.

* Ensures MdiChild on the front if MdiTop.MostFocused isn't valid, like ContentView.

* Add unit test showing MdiChild on the front.

* Fix an issue where NullReferenceException can be throws everywhere while get the Application.MdiChildes property.

---------

Co-authored-by: Tig <tig@users.noreply.github.com>
2023-10-17 13:34:28 -04:00
BDisp
bffc9cb2e8 Fix a label width size issue. 2022-11-17 18:01:03 +00:00
Charlie Kindel
bf1ed31281 Refactored UI Catalog and added tons of unit tests 2022-11-03 15:58:15 -06:00
BDisp
09f005448e Fixes #1800. TextView now uses the same colors as TextField. (#1971)
* Fixes #1800. TextView now uses the same colors as TextField.

* Replacing the textview to default in some scenarios.

* Removing TextView ColorScheme from the Wizard component.

* Changing someText color to be different from the help text color.

* Renamed some color methods as requested.

Co-authored-by: Tig Kindel <tig@users.noreply.github.com>
2022-09-15 06:43:18 -07:00
Charlie Kindel
32ae3cb62f Cleaned up Categories and Scenario descripitons. 2022-04-17 15:48:48 -07:00
Charlie Kindel
83f70cbf39 Revert "Revert "Reorganizing scenarios categories as per #1648""
This reverts commit 359ba385c8.
2022-04-17 14:17:40 -07:00
Charlie Kindel
359ba385c8 Revert "Reorganizing scenarios categories as per #1648"
This reverts commit 3362ca849d.
2022-04-17 14:14:44 -07:00
BDisp
3362ca849d Reorganizing scenarios categories as per #1648 2022-03-17 16:39:15 +00:00
BDisp
239191cde0 Fixes #1434. Regenerating the docs. (#1528)
* Fixes #1434. Regenerating the docs.

* Fixing warnings on docs regeneration and improving.
2021-12-18 05:33:40 -08:00
BDisp
9d767a4171 Dynamic menu/statusbar and Enable property fix. (#1489)
* Fixes both dynamic menu and status bar broken scenarios.

* Fix a bug where the subviews oldEnabled can be overridden, even the superview Enable property hasn't changed.
2021-10-25 12:29:27 -07:00
BDisp
52f48b2044 Fixes #1384. Added a VisibleChanged event on the View class. (#1385)
* Fixes #1384. Added a VisibleChanged event on the View class.

* Getting the last char.

* Fixes #871. Added Enable property to Responder and added Disabled color for all ColorSchemes.

* Added GetNormalColor method to the View being more readable.

* Fixes the contentBottomRightCorner Enable and Visible.

* Fixes #643. Added AddItemAt and RemoveItem to StatusBar and fixed more bugs.

* Typo fixes.

* Fixes #1387. Allowing the UnitTests project to test internal keywords.

* Fixes #1389. Added a unidirectional feature to the Marquee styles to the ProgressBar.

* Fixes #1394. Added ReflectedType to check for overridden.

* Fixes #1396. Using the Loaded event instead the Ready event.

* Fixes #1402. Only WindowsDriver supports horizontal scroll. (#1403)

* Fixes #1402. Only WindowsDriver supports horizontal scroll.

* Fixes ProcessContinuousButtonPressedAsync on all drivers.

* Fixed internal unit test.

* Fixing warning.

* Fixing Editor scenario error.

* Fixes double and triple click on a touchpad.

* Ensuring reset the counting.

* Allowing touchpad double and triple click with one finger on CursesDriver.

* Allowing touchpad double and triple click with one finger on WindowsDriver.

* Fixes #1414. Fixed multi toplevels and mdi container issues.

* Improving EnsureVisibleBounds and PositionToplevel.

* Added mouseGrabView to the ResetState method.

* Changing namespace.

* Allowing file type on the SaveDialog.

* Fixes SaveDialogs writing the extension twice.
2021-08-11 02:56:30 -07:00
BDisp
6be3aab2ce Changed casing for Shortcut. 2020-10-26 18:56:24 +00:00
BDisp
b1cc2f8035 Implemented ShortCut in the View class within the UICatalog example. 2020-10-26 12:23:11 +00:00
BDisp
01d4b4f55f Added wide improvements on keys managements. 2020-10-26 00:46:51 +00:00
BDisp
4729f46726 MenuBar.ShortCutDelimiter cannot be empty. 2020-10-24 01:35:18 +01:00
BDisp
f713f36e5c typo. 2020-10-24 01:35:17 +01:00
BDisp
21650576eb Recover from rebase. 2020-10-24 01:35:04 +01:00
Artyom
64fdcea6b5 Define View actions as events 2020-09-23 01:26:46 +03:00
Artyom
bd7610df74 Migrate all controls to C# events 2020-09-23 01:13:52 +03:00
Artyom
28805f3c5c Use C# events in more controls 2020-09-23 01:07:26 +03:00
Artyom
6aef632633 Button.Clicked as a C# event 2020-09-23 01:01:53 +03:00
BDisp
109fd25c9e Fixes #644. Added a UICatalog Scenario for a dynamic menu bar. 2020-08-03 03:08:32 +01:00