-
-
Notifications
You must be signed in to change notification settings - Fork 18
allow to change container (for example FlexboxLayout powerful combina… #17
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
Conversation
|
Hello, thanks for the suggestion, this looks very interesting. I am wondering how you are using the FlexboxLayout without changing the underlying layout resource. Could you provide a usage example on this? Another option I see here is to extend the SimpleFormDialog and overwrite the onCreateContentView method. Any thoughts about this? Regards |
|
I extends SimpleFormDialog and override onCreateContentView like you suggest in Wiki. I think better way is to extends from CustomViewDialog and add this to library. On the other hand we can create decorator.
Regards |
|
I see. |
…ts into peoxnen-master Separate method to populate container with form elements See #17
|
I think the best practice is to extend Using the method Here is an example on how to use it: public class FlexboxFormDialog extends SimpleFormDialog {
public static FlexboxFormDialog build(){
return new FlexboxFormDialog();
}
@Override
public View onCreateContentView(Bundle savedInstanceState) {
// inflate custom view
View view = inflate(R.layout.dialog_form_flex);
FlexboxLayout container = (FlexboxLayout) view.findViewById(R.id.container);
// TODO: set up flexbox-layout
populateContainer(container, savedInstanceState);
return view;
}
} |
|
It's good idea :) Thx. |
|
Linked in Wiki. |
Hello,
If you allow to change Countainer for forms you can change LinearLayout to FlexboxLayout. Its pawerful comibination and you can build dynamic dialog with many items. You can make specific dialog's layout for tablets. I send u example https://ibb.co/ks8rnb. With this change your library would be more elastic and pawerful.
In the other way we can change this layout in your library and set default values to present in like LinearLayout but it require add FlexboxLayout https://github.com/google/flexbox-layout (its from Google).
Reargs,
Witold Sieński