New Flutter project Android Studio Demo App counter app or Application template not an option - flutter

So I am following this tutorial, which is quite recent, my Android Studio build is from May 16 so not too far off from this vid's upload date: https://youtu.be/CD1Y2DmL5JM?t=531
Notice how the welcome screen looks right at the time the vid starts on the point I linked. But for me, the welcome screen looks like this, why?:
Also, when I click "new flutter project" in the top right, this screen shows up which is different for the vid, why?:
Spent an hour but can't find anything. Now I can create a new flutter project and selected the right location for my flutter and dark SDK, and have both flutter and dart plugins installed. But the option of the standard "Application" template is not a standard option. Looks at the above options, I've tried them all and none are the counter app. In vscode I typed "flutter new project" in global search, and it gave the "Application" template, and running in with the emulator open showed the counter app. But where is the option in Android Studio?

On the left side pane, you actually have to select Flutter, input your SDK location, then click next from the same panel. Don't click next while Dart is selected otherwise you will get the options you see above:
After this it will take you to making a new Flutter project, not a Dart project. Then next to "Project Type:", choose "Application".

Related

Cannot find Device Choose Button in Android Studio

I have used Android Studio for several weeks,I use my iPhone to Flutter Attach .
Today I create a new Project, I cannot find the Device Choose Button, Where is the button to Change Device ?
As the Pictures below, I have Two projects, another Project has the "Device Choose Button"
Close the project
Restart your IDE
Do it several times [4-5 times]

Unable to Extract Widget Android studio

I am using Android studio chipmunk 2021.2.1 patch 2 for Apple M1 chip ... created a flutter project with patch 1 ... code is working fine but some android studio features not working ...
Flutter Outline shows the source code tree but I am unable to Export any widget nither directly from the editor nor from Eflutter Outline Tab ...
doubleclick on widget tree -> refector -> Extract Flutter Widget ...
Following popup appears but nothing happens on clicking Refactor...
The same thing works fine for the Extract Method...
Flutter Outline shows the code tree but it's also not extracting any Widget...
Only the Export Method button works fine here... it also does not show Wrapping any widget all buttons are disabled ...
The following suggestion bulb is also not showing anything for this project... (This screenshot is from another project)
Unable to rename anything... it shows an error...
This error does not make any sense.
And all things are working fine for the other flutter project I downloaded from Github...
I don't know why this thing happening only for this project and working fine for other projects.

"Widget Tree View" in Android Studio Editor?

I'm using the most current version of Android Studio to develop Flutter Apps/Flutter 2.5.3.
In some projects, I can see the widget tree graphic lines in the editor, but sometimes when creating a new Flutter project it does not appear. And I'm unable to find the option to turn it on. Does anybody know the secret switch?
Thanks
Good editor settings: (see the yellow marked widget tree lines)
Bad editor settings: (no tree view... :-( )
Go to "File/Settings," then search for "Flutter" and enable "Show UI Guides for build methods":

"Image Asset" option missing in Android studio for flutter project

To change the app icon for the flutter app and to fillup, the entire circle with the custom icon looking for the "Image Asset" option but couldn't find it in the following menu?
Would recommend setting app icon via this package https://pub.dev/packages/flutter_launcher_icons
If you want to do it via android studio open android folder separately:
I wish that tools come back to flutter again. For now:
Close your flutter project and then open the android folder of your flutter project as an android project. It takes a while to sync. After that, you can access to New Image Asset Tool.
I know it's not the best solution, but at least, you can have your customized icons.

Troubleshooting on device with Titanium for iPhone

On Xcode when you build on device you can troubleshoot the app within the console. How can i do that with Titanium? It's very difficult without troubleshooting
What you can do is use the Ti.API.info('whatever') method to log everything you need and will help in debugging then while you run your app on the device and it is connected to your computer, just open xcode -> go to organizer -> click on your device -> and select console. Every Ti.API.info() log you do in your app will show up in the console.
Titanium's SDK (http://www.appcelerator.com/platform/titanium-sdk) is Eclipse with the Aptana plug-in. You can do the same debugging you'd do in Eclipse: set break points, step through code, set watch points, ...
To run your app in debug mode, start by setting some break points in your app. To do that right-click on the line number that's on the far left of our line of code and select "Toggle Breakpoint". Next, towards the top of the Project Explorer panel are several icons. One of them is debug. Click on that debug's dropdown menu and select the iphone emulator or ipad emulator. The app will compile for debug and run the emulator you chose. From this point on, everything is like debugging on Eclipse.