Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 5 years ago.
Improve this question
How can i remove the ion-tabs once its loaded
I am working on a chat application which is almost complete. The issue is that when i login to tabspage, then when i try to logout and it takes to the login page, The bottom ion-tabs are still being showed in login page now.
How can i remove the ion-tabs once it loaded ?
I have searched the internet and didn't found any valid resolve to this problem. I really need solution to this fast.
Following are some screeenshot to explain the situation, Thanks.
Before login screenshot
Dashboard with tabs page loaded
AFTER LOGOUT (loginpage), still tabs are visible
You are changing the root of the tab, remember that each tab has its own navigation stack. By default, pages are cached and left in the DOM if they are navigated away from but still in the navigation stack (the exiting page on a push() for example). They are destroyed when removed from the navigation stack (on pop() or setRoot()). To set a full new root outside the tabs, do something like:
this.app.getRootNav().setRoot(Login);
Hope this helps
Related
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed yesterday.
Improve this question
I am trying to make a simple contact app in flutter. In homepage there is + icon(floating Action Button) which will navigate to next screen where you can enter Name and Contact Number of the person.
On homescreen we will be able to see those contacts in listview builder.If i tap on and any card of contact it will navigate to edit screen.
I am trying to make add and edit on same screen. But in case of edit screen TextEditingController should show initial data and in case of add screen it should show hintText.
I don't know how to make both add and edit on same page. Please help me with this.
I first tried making two screens separate which i could do. But now i am looking for way to make both add and edit screen on same page. So that i don't have to write same code again.
Use a flog to check if the screen is to add or edit, if its to add set null to initialValue of TextFormField otherwise provide the value.
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 5 months ago.
Improve this question
I am developing an app to learn English with flutter. I have a problem with my app when I ran it on Android devices( IOS is okay).
The problem is when I open my app and click on the button menu like Intermediate(to clarify my button still can't click, I just click on the screen) it will active my navigation bar on the phone first(like my screen is not active) and then I click it again it will be okay.
So I want to ask how I can change (or just a keyword) to get my button menu can click on the first time not click on my screen first?
The second time click is okay(screen is active or like that)
I have already found my answers guys.
I just forgot to display my system bottom bar.
SystemChrome.setEnabledSystemUIOverlays(SystemUiOverlay.values));
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I'm relatively new to programing in general and am currently designing a database project but now I ran into a logic problem which my head cant get straight.
The problem is that I have a view controller that loads in a list of things from the database and than when you click on it it opens a detail, from that detail there is a button that loads in a list like the previous one we came from so I use the same view controller and just request different data. So far, everything is nice and dandy.
But now comes the problem there is a back function so when I now press back once I go back to the detail and than when I press back a second time it loads the last data that I had loaded on that list so it loads the wrong data.
A good example of what I would like to have is the Facebook friend function when I click on my friends it loads a list and than I can click on their friends I see the same list with different data but when I go back two steps it loads in my friends again. I made it work with a very confusing and impractical system of registers but this is very bad because it sometimes throws errors.
So does anyone know how I could achieve what I want?
When you "reuse" this view controller, I would suggest creating a new instance of that view controller each time. This way, (assuming you avoid use of any global variables, but rather only use properties of the class) you're guaranteed that each time you create new instance of the view controller, it won't affect other instances that might exist elsewhere in the navigation controller's stack of previously instantiated view controllers.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
I would like to create a page similar to the one where the user can add a note in the Momento app (screenshot below).
What's the best way to structure the View Controllers for this page? There is a tab-like menu in the center of the page. On the top half of the screen, is a view; and at the bottom-half, you get a keyboard (when entering text).
MY NEED : entering a note which can have three types of text (so three tabs) and a picture -> so four tabs in all.
On some analysis, goggle'ing, and thinking, I can think of these possibilities:
OPTION 1
A TabBarController with 4 tabs (but then I wouldn't be able to place the tab in the middle of the screen like in Momento app & I read (in some Stackoverflow discussions) that Apple guidelines don't recommend changing the tab bar from its natural position either.
OPTION 2
Have a view controller, say MyController. This will have 4 buttons (arranged next to each other in the middle of the screen, so that they appear like tabs).
Have one UIView object for the top-half of the page.
Have another UIView object for the bottom-half of the page.
Based on which of the four buttons is selected, I vary the content displayed in the top & bottom UIView objects.
Option 2 sounds good to me. But, I wanted to get an opinion on if it's correct, or is there some better way to achieve this? Thoughts please?
You should use a UITextView and set it's inputView as a view with those buttons. It should automatically slide with the keyboard just as you want it.
Hope this helps.
Cheers!
OK, here is where I would start. Two issues; the tabBar and handling the keyboard. The rest is just pushing a popping appropriate view controllers.
The TabBar: First Apple has some example code that deals with the Keyboard Accessory component which is probably how Momento renders their tabBarController like thingie. Here is the link. Their example handles the keyboard in a 'one off' way, unique to this particular app.
The Keyboard: As for a more generic approach to handing the keyboard, you may want to look at Michael Tyson's TPKeyboardAvoiding component on github. Here's the link for that one. The TPKeyboardAvoiding is quite nice in that it is a drop in component that handles keyboard issues for UITableView as well as UIScrollView.
One thing I haven't checked is if Mike's stuff is smart enough to handle the extra height on the Keyboard when it has an Accessory attached. (It's pretty smart though...).
Hope this helps.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I want to implement a splash screen in my application, like if the username and password are already saved in nsuserdefaults and username password fields are also filled up, then when the user starts his application, a splash screen with progress bar and a cancel button should come up, and application should be logged in automatically.
And in case if user clicks on the cancel button, that splash screen would be removed from view and the login screen would be shown.
Is there any example/tutorial related to this?
thanx in advance
First of all the purpose of the splash screen is to make the user wait until the application loads into the iOS. Of course you can achieve your requirement by placing an image and a cancel button. But I afraid that anyhow when your app is launched for the first time you wont get the control for upto 4 to 5 seconds. So my suggestion would be to fix a splash screen first (traditional one) and then when you get the control, perhaps in applicationDidFinishLaunching add a progress bar and a cancel button.