Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inspector: Add new AdvancedSlider control #192

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

EchterAgo
Copy link
Contributor

@EchterAgo EchterAgo commented Jun 18, 2016

Replace the old RangeEditor and TextBox numeric editors with the new
advanced slider control. The user can use a combination of ALT, CTRL and
SHIFT keys to adjust the rate of change. The user can also double click
the value to edit the value numerically.

Signed-off-by: Axel Gembe [email protected]

This needs #193 merged first.

@EchterAgo
Copy link
Contributor Author

This is a large one. Sadly it can not be used with nullable values.

if (propertyDescriptor.PropertyType == typeof(double))
{
return new AdvancedSliderEditorViewModel<double>((double) rangeAttribute.Minimum, (double) rangeAttribute.Maximum) {
Speed = 0.1
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should maybe come from an attribute as well.

@EchterAgo
Copy link
Contributor Author

Rebased on top of #192

@EchterAgo
Copy link
Contributor Author

Updated patch to make it easier to set the cursor inside the text field and to make the text box use the key down event for ending editing so that other controls do not handle the key down event first.

@EchterAgo
Copy link
Contributor Author

Updated to support keyboard focus

@tgjones
Copy link
Owner

tgjones commented Jul 6, 2016

This looks quite nice. I'm concerned about the overlap with NumericTextBox though (as seen in the MonoGame demo, in the Vector3 property editor). Could we extend NumericTextBox instead of introducting a new control?

In any case, I'll wait till #192 is merged, so that the diff here is easier to review.

@EchterAgo
Copy link
Contributor Author

Rebased

@tgjones
Copy link
Owner

tgjones commented Nov 6, 2018

Please could you rebase this again?

@EchterAgo
Copy link
Contributor Author

I'll do that, but I'd like to look into addressing your concerns regarding NumericTextBox overlap first. I think you should take a look at merging #298, it is a simple bugfix.

@EchterAgo EchterAgo force-pushed the advanced_slider branch 3 times, most recently from 1234489 to 3249508 Compare November 8, 2018 10:10
Replace the old RangeEditor and TextBox numeric editors with the new
advanced slider control. The user can use a combination of ALT, CTRL and
SHIFT keys to adjust the rate of change. The user can also double click
the value to edit the value numerically.

Signed-off-by: Axel Gembe <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants