My First Program (and app), CryptoKeep Portfolio
-
Great app thanks for spending your time on this! Runs perfectly on nexus 4.
-
Thanks Kris, and you’re welcome! Just to let you guys know I cleaned it up a little and added the Feathercoin banner that links to our site
-
Good work Aysyr :D
-
Hi just a note about the updated version - it seems to be too large for my screen and the actual USD value is not visible. Hope its a simple fix :)
-
Hmm that’s odd…especially since I updated it to smaller sizes. I’ll take a look at it when I get the chance. Would you be able to take a screenshot for me so I know how it’s overflowing?
-
[quote name=“kris_davison” post=“28644” timestamp=“1379703478”]
Hi just a note about the updated version - it seems to be too large for my screen and the actual USD value is not visible. Hope its a simple fix :)
[/quote]I have exactly the same problem on my tablet PC. the display is too large and the right side of the screen is not visible. See attachd pic
[attachment deleted by admin]
-
Hi sorry only noticed the post. It must be relating to it being a smaller size? I’m on a nexus 4 and before the update with the new banner it all looked perfect. Now it looks very similar to the Other screenshot!
Cheers Kris[attachment deleted by admin]
-
Ah okay, so you’re using tablets. The app was made with a phone’s emulator so the sizing was based on that… but that still makes no sense. If it was fine during the first version, it should still look fine since what I did was actually make fonts [i]smaller[/i] so you would think it fit better if anything. I’ll take a look at it after I finish my hw later today
-
[quote name=“aysyr” post=“28729” timestamp=“1379776623”]
Ah okay, so you’re using tablets. The app was made with a phone’s emulator so the sizing was based on that… but that still makes no sense. If it was fine during the first version, it should still look fine since what I did was actually make fonts [i]smaller[/i] so you would think it fit better if anything. I’ll take a look at it after I finish my hw later today
[/quote]The Nexus4 is a phone Aysyr, I noticed since the introduction of the banner that the layout is not as aesthetically pleasing as before. There is also what appears to be a data area slightly visible off screen. $ signs etc.
It still all works as should though 8) -
[quote name=“UKMark” post=“28731” timestamp=“1379777619”]
The Nexus4 is a phone Aysyr, I noticed since the introduction of the banner that the layout is not as aesthetically pleasing as before. There is also what appears to be a data area slightly visible off screen. $ signs etc.
It still all works as should though 8)
[/quote]Aww really? I thought the banner made it look better :P But yea it SHOULD work as well as before in terms of resolution, but it’s so confusing. The banner itself is 350 pixels and fits fine on their screen, and the total of all the objects in each row only goes to 32x pixels wide, so there’s no reason it should overflow. But I’m trying to resize everything again so hopefully this time it’ll fit again.
-
I’m pretty sure those are applicable to apps too. However the thing was I didn’t use code to write it, I used AppInventor where you drag blocks for your statements, so it’s really limited in terms of changing things for compatibility. Ideally I would’ve liked to have learned Java and written it, but it would’ve taken a lot longer with my schedule since I would’ve had to learn it first, and I probably wouldn’t even be 1/2 done the app if that was the case lol. I might try to learn Java and rewrite it over the winter break if I have the time.
-
Just an update… I added a couple stuff to the app and was able to get it to reflect the BTC-e average BTC price, so all prices are now based on it (was having issues with it before, so it had been using Mt. Gox). Also reformatted some so let me know if it’s still going over the screen.
Let me know any suggestions you guys have that I might be able to implement and a few decent coins I can add before making a post for it on bitcointalk.org so we can get Feathercoin some publicity with the banner :P Let me know if I can clean up anything (other than the graphics).
Thanks guys!
-
Adding GBP & EURO conversions would be a nice addition. 8)
-
[quote name=“UKMark” post=“28913” timestamp=“1379926067”]
Adding GBP & EURO conversions would be a nice addition. 8)
[/quote]That’s actually on my to do list ;D
-
Just got the update on my tablet and the display is ok now. Just the images are not as sharp as they probably are on a mobile, as the tablet screen is much larger and needs higher resolution of the pictures.
Well done, aysyr :)
[attachment deleted by admin]
-
[quote name=“iawgoM” post=“28928” timestamp=“1379939899”]
[quote author=Wellenreiter link=topic=3689.msg28923#msg28923 date=1379932799]
Just the images are not as sharp
[/quote]One thing I don’t understand - even the text part is smudgy and not sharp…how come?
[/quote]Would it have anything to do with the tablet resizing the fonts? I doubt that would make a difference in clarity though right?
And thanks Wellenreiter!
-
I’ve just got the update too and it looks great. Thanks for the hard work.
As a side note if you need any pointers learning Java let me know as that’s my day job. (Not touched android much tho) -
[quote name=“kris_davison” post=“28961” timestamp=“1379963839”]
I’ve just got the update too and it looks great. Thanks for the hard work.
As a side note if you need any pointers learning Java let me know as that’s my day job. (Not touched android much tho)
[/quote]Orly? Do you mind if I ask you a question that most developers get really wrong in Java?
-
Yeah go ahead!
-
[quote name=“kris_davison” post=“28974” timestamp=“1379976181”]
Yeah go ahead!
[/quote]Ok. I’ve got the following Class structure, which I wrote myself:
[code]
public abstract class FileSystemNode{
…
}public class File extends FileSystemNode{
…
}public class Directory extends FileSystemNode{
public List myNodes;
}
[/code]As you can see, File and Directory extend FileSystemNode. Directory contains 0 or more FileSystemNodes (which is to say it contains files and directories).
Some of the methods in FSNode are common to both classes, but both File and Directory expose methods which FileSystemNode doesn’t have (files have byte arrays of their contents, directories contain other files and directories).
Ok. So far so good. You might envision a File system specific factory which on different platforms creates and populates these differently. Whatever.
Now I’m going to write a Backup client, which will iterate recursively through all the files and directories, and back up their contents. So I start writing code:
[code]
public class BackupClient{
…public void backup(Directory aRootDirectory){
for(FileSystemNode node : aRootDirectory.myNodes){
…
[/code]And… I’m stuck. I need to know if the current ‘node’ is a File or a Directory, because if it’s a file, I’ll read the bytes, but if it’s a directory, I need to recurse, and do this all over again.
Now the thing that most developers will do is write an if statement using instance of and a cast, shown here:
[code]
if(node instanceOf File){
handleFile((File) node);
}else if(node instanceOf Directory){
handleDirectory((Directory) node);
}else{
throw …;
}
[/code]This sucks for several reasons. First of all it requires a cast, which should be your first clue that you did something wrong. The entire class hierarchy of FileSystemNode has leaked into this BackupClient class, and whenever the hierarchy changes, this code is going to break, but not until run-time, when that exception gets thrown, likely on your customers machine. If my developer implemented this solution, I’d give them 1+ point for using a oft-forgotten keyword, but minus several thousand for totally breaking encapsulation and making a mess of the solution.
So, my challenge to you is: Resolve if FileSystemNode node in our for loop is a File, or a Directory, and do the appropriate operation without using an explicit cast, or even an if/switch statement. Do this in a way that will cause the compiler to CHOKE if you add another descendant of FileSystemNode (ie SymLink, ResourceFork, whatever) without updating the code that uses it (BackupClient in this case).
Bonus points if you can name the Gang of Four pattern that captures this solution.
Let me know if you get stuck, I’ll give you a clue.