XDATV Noter

Search This thread

AdamOutler

Retired Senior Recognized Developer
Feb 18, 2011
5,224
9,827
Miami, Fl̨̞̲̟̦̀̈̃͛҃҅͟orida
Introduction
Hey guys. I'm working on an Android application for XDATV. We've never really featured a fully functional application on XDATV before. I thought it was high time we did that.

Noter is a note taking application. It is a good representation of several basic Anrdoid APIs.

source & download
Subversion Repository: http://xda-adk.googlecode.com
Project Checkout: svn checkout http://xda-adk.googlecode.com/svn/trunk/EclipseProjects/xdatv-noter
Image of app: http://i50.tinypic.com/qs8ro8.png
App download: https://code.google.com/p/xda-adk/downloads/detail?name=XDATVNoter.apk

goals
Demonstrate proper coding style and development.
Introduce n00bs to app development.
Make an expandable single-class app which will have the ability to integrate into future projects.

Questions and Contributions
If you have a question, please ask. I am in no way, shape, or form an Android app development expert. I do java more than anything else, not so much with Android. If you've got something to contribute, please do! If you spot a problem in the code, then let me know and I'll give you credit on the SVN Commit.
 
Last edited:

Archer

Inactive Recognized Developer / Retired Senior Mod
Jul 9, 2008
14,002
4,003
Manchester
Google Pixel 8 Pro
I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.
 
  • Like
Reactions: AdamOutler

AdamOutler

Retired Senior Recognized Developer
Feb 18, 2011
5,224
9,827
Miami, Fl̨̞̲̟̦̀̈̃͛҃҅͟orida
I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.

Yeah! That's the idea. Once the video is released I will publish it in the OP as well. I hope its understandable. If not, that's why we have this thread available.
 
  • Like
Reactions: Archer

klownk

Member
Aug 13, 2009
23
1
hi adam! In the title of the video you mentioned testing, which i missed a little in the video. what methods or tools do you use for unit testing and stuff?
 
  • Like
Reactions: AdamOutler

1031Vulcan

Member
Sep 1, 2012
14
3
McCalla, Alabama
I'm sorry to clog up this thread with a post about help, but I couldn't find a thread for the series for tutorials Adam released about a year ago.

At around 8:34 in part one (http://www.youtube.com/watch?list=P...=31cxmLN09ss&feature=player_detailpage#t=513s), Adam adds a button to his test-app thing. It will not let me do this. It shows a no symbol over my cursor when I drag it over the display. I selected the .xml through res and layout just like he did. Only different thing I can tell I am doing is using 4.0 API instead of 2.3.

I have no experience with coding or doing work with Android so I apologize for any common mistakes.
 
  • Like
Reactions: AdamOutler

ateeq72

Senior Member
Dec 28, 2011
323
306
Chennai
OnePlus 7
hi der!
is their any file named "notes.txt" is created.? if yes where can i find it? :D

and yeah thank you!.. am just a beginner and this helped me a lot! :D

Edit :

i also added "WRITE_EXTERNAL_STORAGE" permission in android manifest!
but still cant find noter.txt file anywhere as mentions in MainActivity.java file! :(
please help! :(
 
Last edited:
  • Like
Reactions: AdamOutler

AdamOutler

Retired Senior Recognized Developer
Feb 18, 2011
5,224
9,827
Miami, Fl̨̞̲̟̦̀̈̃͛҃҅͟orida
I'm sorry to clog up this thread with a post about help, but I couldn't find a thread for the series for tutorials Adam released about a year ago.

At around 8:34 in part one (http://www.youtube.com/watch?list=P...=31cxmLN09ss&feature=player_detailpage#t=513s), Adam adds a button to his test-app thing. It will not let me do this. It shows a no symbol over my cursor when I drag it over the display. I selected the .xml through res and layout just like he did. Only different thing I can tell I am doing is using 4.0 API instead of 2.3.

I have no experience with coding or doing work with Android so I apologize for any common mistakes.
You have to drag it from the bar on the left. There are a set of controls over there which you can select and drag/drop.


hi der!
is their any file named "notes.txt" is created.? if yes where can i find it? :D

and yeah thank you!.. am just a beginner and this helped me a lot! :D

Edit :

i also added "WRITE_EXTERNAL_STORAGE" permission in android manifest!
but still cant find noter.txt file anywhere as mentions in MainActivity.java file! :(
please help! :(
Its in /data/data/tv.xda.noter/files/notes.txt You need to be "Noter" or root to access this file.
 

tmka

Member
Jul 25, 2012
16
6
Seattle
Nice video, thanks!

Don't forget to close your output stream; probably more dangerous than forgetting to close an input stream if anything's buffered. Also it's maybe stylistic, but I much prefer Reader/Writer for textual data. If you like System.out style, you can do:

PrintWriter out = new PrintWriter(new OutputStreamWriter(openFileOutput(FILENAME, Context.MODE_APPEND)));
 

marty331

Senior Member
Jun 29, 2011
829
249
Dallas, TX
Really great job Adam. I'm going to watch a second time tint and build the app along with the video, you have some points that are helpful that I hadn't thought of before.

Edit:

Adam, I just watched and built along with the video. What action did you do at 15:24, I can see you did something called Refactor, but I'm not familiar with it. Can you explain what it does and why you did it? Thank you!!!

Sent from my Nexus 7 using xda premium
 
Last edited:
  • Like
Reactions: AdamOutler

AdamOutler

Retired Senior Recognized Developer
Feb 18, 2011
5,224
9,827
Miami, Fl̨̞̲̟̦̀̈̃͛҃҅͟orida
Really great job Adam. I'm going to watch a second time tint and build the app along with the video, you have some points that are helpful that I hadn't thought of before.

Edit:

Adam, I just watched and built along with the video. What action did you do at 15:24, I can see you did something called Refactor, but I'm not familiar with it. Can you explain what it does and why you did it? Thank you!!!

Sent from my Nexus 7 using xda premium
I just moved some code into methods and changed some names. Refactoring means renaming or moving or a number of other operations. Basically, you clean things up with a refactoring. Refactoring is an operation the IDE does safely so when methods or variables move, all the calls point at the newly refactored method or variable.
 
  • Like
Reactions: marty331

marty331

Senior Member
Jun 29, 2011
829
249
Dallas, TX
I just moved some code into methods and changed some names. Refactoring means renaming or moving or a number of other operations. Basically, you clean things up with a refactoring. Refactoring is an operation the IDE does safely so when methods or variables move, all the calls point at the newly refactored method or variable.

Awesome, great to know. I'll try using this in the future!
 

A random package

Senior Member
Aug 5, 2010
260
635
St. George
Sweet tutorial! Will be using this as starting point for the app I want to develop. Quick issue though. When I first implement the OnClickListener, it has an error with 56 fixes available, the top two being imports. Which one of these do I pick? I see you chose something from a dropdown, but the video sped up and I can't see which one it was. :)
 

octobclrnts

Senior Member
Apr 26, 2009
67
13
Pittsburgh
Sweet tutorial! Will be using this as starting point for the app I want to develop. Quick issue though. When I first implement the OnClickListener, it has an error with 56 fixes available, the top two being imports. Which one of these do I pick? I see you chose something from a dropdown, but the video sped up and I can't see which one it was. :)

There are 2 common OnClickListener classes like you say, one of them is probably View.OnClickListener and the other DialogInterface.OnClickListener. Use the View.OnClickListener any time that you are attaching it to a widget in your normal layout. Use the DialogInterface.OnClickListnener any time you have created an AlertDialog and are listening to one of its buttons.
 
  • Like
Reactions: A random package

pawan.dewani

New member
Feb 18, 2014
1
0
File Location

Hey Adam
In the video you haven't mentioned how to choose the file location.
Please guide me on this.

Thanks :)
 

Top Liked Posts

  • There are no posts matching your filters.
  • 5
    Introduction
    Hey guys. I'm working on an Android application for XDATV. We've never really featured a fully functional application on XDATV before. I thought it was high time we did that.

    Noter is a note taking application. It is a good representation of several basic Anrdoid APIs.

    source & download
    Subversion Repository: http://xda-adk.googlecode.com
    Project Checkout: svn checkout http://xda-adk.googlecode.com/svn/trunk/EclipseProjects/xdatv-noter
    Image of app: http://i50.tinypic.com/qs8ro8.png
    App download: https://code.google.com/p/xda-adk/downloads/detail?name=XDATVNoter.apk

    goals
    Demonstrate proper coding style and development.
    Introduce n00bs to app development.
    Make an expandable single-class app which will have the ability to integrate into future projects.

    Questions and Contributions
    If you have a question, please ask. I am in no way, shape, or form an Android app development expert. I do java more than anything else, not so much with Android. If you've got something to contribute, please do! If you spot a problem in the code, then let me know and I'll give you credit on the SVN Commit.
    1
    I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.
    1
    I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.

    Yeah! That's the idea. Once the video is released I will publish it in the OP as well. I hope its understandable. If not, that's why we have this thread available.
    1
    The onclick view thing is handy:good:
    1
    hi adam! In the title of the video you mentioned testing, which i missed a little in the video. what methods or tools do you use for unit testing and stuff?