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
[TIMOB-23974] Android: Add property to release space when hiding an object #8458
Conversation
@@ -1447,6 +1447,11 @@ | |||
/** | |||
* @module.api | |||
*/ | |||
public static final String PROPERTY_FREE_SPACE = "freeSpace"; |
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 don't like the property-name. What about a more "boolean-like" property, e.g. showSpaceWhenHidden
or truncateSpace
? Or even expose the used constant directly and introduce a hiddenBahavior
property. That keeps it more flexible, allows more configuration and sounds more native. Thanks!
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.
Good idea! I'll go for hiddenBehaviour: Ti.UI.VIEW_GONE | Ti.UI.VIEW_INVISIBLE
Then it looks almost like the native View.GONE and View.INVISIBLE
type: Boolean | ||
default: false | ||
platforms: [android] | ||
since: 6.0.0 |
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.
6.0.0 is already in QE-testing, please set it to 6.1.0 and we'll try to review it in that timeframe. Thx!
Looks great now! Putting into further review for 6.1.0. |
@@ -178,6 +178,9 @@ | |||
@Kroll.constant public static final int INPUT_TYPE_CLASS_NUMBER = InputType.TYPE_CLASS_NUMBER; | |||
@Kroll.constant public static final int INPUT_TYPE_CLASS_TEXT = InputType.TYPE_CLASS_TEXT; | |||
|
|||
@Kroll.constant public static final int VIEW_GONE = View.GONE; | |||
@Kroll.constant public static final int VIEW_INVISIBLE = View.INVISIBLE; |
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.
Thinking about it, we might want to rename them to Ti.UI.HIDDEN_BEHAVIOR_GONE
and Ti.UI.HIDDEN_BEHAVIOR_INVISIBLE
. What do you think? And please add + validate the docs for the constants, they are not documented, yet.
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.
Sure, changed the property and updated the constants inside the doc! HIDDEN_BEHAVIOR_INVISIBLE
is fine, too. So its more connected to the property name
CR + FT passed, PR approved! Great work! 🚀 |
JIRA: https://jira.appcelerator.org/browse/TIMOB-23974