-
Notifications
You must be signed in to change notification settings - Fork 191
Add setAutoscaleDisabled API to provide a better means to disabling autoscaling at widget level #2863
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
base: master
Are you sure you want to change the base?
Conversation
|
This pull request changes some projects for the first time in this development cycle. Warning 🚧 This PR cannot be modified by maintainers because edits are disabled or it is created from an organization repository. To obtain the required changes apply the git patch manually as an additional commit. Git patchFurther information are available in Common Build Issues - Missing version increments. |
|
@amartya4256 can you please add a meaningful title and description to the PR, even if it's still a draft? |
cb3cc53 to
2a1545f
Compare
2a1545f to
f5b90b2
Compare
8ff51cb to
85a74d1
Compare
bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/AutoscalingMode.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/AutoscalingMode.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/AutoscalingMode.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/graphics/AutoscalingMode.java
Outdated
Show resolved
Hide resolved
85a74d1 to
d858871
Compare
2c97d55 to
ddd5eab
Compare
|
@amartya4256 since the dependent PR is merged, this can/should be rebased on master now |
1d665b4 to
c4655bd
Compare
HeikoKlare
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have not tested yet, but the code looks fine at a first glance. For now I have some comments regarding code style and documentation.
bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
c4655bd to
3517a82
Compare
bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Control.java
Outdated
Show resolved
Hide resolved
3517a82 to
7834fb1
Compare
This commit adds an API to set Autoscaling Modes using the new enum AutoscalingMode with types Enabled, Disabled and Disabled_Inherited. Moreover, it also provides an API Shell#getNativeZoom to still make the consumer be able to obtain the actual zoom at a screen. These features are only enabled on win32 and will not perform any action on other platforms if called.
7834fb1 to
2b5c0a7
Compare
akoch-yatta
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I tested it with the current implementation in GEF that uses the existing DATA_ fields and adapted it with the new API methods to ensure it still works as expected
This PR provides a new API
setAutoscaleDisabledto provide a better means of disabling autoscaling at widget level across all the platforms. The current implementation is intended to return a false when this method is called in cocoa and GTK and only perform an action win32 and return since we do not support widget level autoscaling control on GTK and cocoa yet.The convention of the method is as follows:
Things to be done:
depends on #2930