« first day (431 days earlier)      last day (4527 days later) » 

2:24 AM
Hey
Hello everyone
 
GPS problem:
Well, I live in Surabaya, Indonesia and my Droid believes that I'm in Jojakarta, Indonesia. When I use applications like CellFinder or even Google Maps, it shows that I'm in California. <<sigh>>
 
That really stinks
 
user457812
You know what else stinks? Brussels sprouts.
 
user457812
And cat breath.
 
I suppose so
@DevYudh is it possible that your problem is more with the carrier and not with the actual phone?
 
user457812
2:44 AM
Is it possible you enabled a mock location?
 
3:00 AM
 
Does anyone have any experience building an application into a "launcher" app?
 
 
2 hours later…
5:03 AM
I love John Pinette
 
SPK
5:38 AM
@ all anyone know the answer for this question means, just answer it.
0
Q: Integrating BackgroundServite to my app?

SPKI'm doing one application like raising email intent by time using AlarmManager. In this app, the Email intent raising by time perfectly. If we set one time for raising Email intent, it'll work. If we restart the device, before the time of event is reached. Then, the app should be work. But, its...

 
 
3 hours later…
8:58 AM
Morning.
 
Hey octopus
 
Do you know the movie Hancock?
 
I've heard of it
 
You should watch it, otherwise I can't use that phrase.
Do it right now.
:D
 
Look, I'm just here for the free tuna.
 
9:07 AM
I want this CuBox thing from SolidRun.
 
cost?
 
Someone should make an Android port that turns old phones into set-top boxes
 
@ProfSmiles Welcome to the room.
 
Alright peeps
 
9:12 AM
:O
 
@Glitch There you go, now you have another Aussie to support you. :)
 
Who what where?!
 
Perth is literally on the other side of the country :P
 
I actually want someone to turn a phone into a Seedbox
If that's possible
 
9:14 AM
Oh! I can see a Python tag in his profile. I already like him. :P
 
How much were they?
Cubs?
er, Cubes.
 
@Graeme 99€.
 
Sexy
If I knew about hardware I/O I would preorder one
 
@Glitch You can easily get there with your bike.
 
9:19 AM
sneak peak at a new Lux feature...
I wish Android let you set an app-wide font, or at least let you set the font in a style
seriously... this is retarded
 
I agree.
It is a pain to set the font for every damn TextView.
 
I was watching a video by one of the devs of Square
and they came up with a hacky way to set an app-wide font
 
So, over christmas I'm going to make some teeny tiny one off apps just to see what the Google Marketplace thing is all about.
 
@Glitch I'd suggest you put the yellow line behind the text.
 
Do you both have experience in it?
 
9:24 AM
Experience in what?
 
@Graeme the marketplace? yeah
 
@Glitch You can set the app wide font really easy
Want the code?
 
@OctavianDamiean behind?
@Graeme sure
 
@Glitch was the super rich bastard that sells thousands of copies of his app on the market everyday.
 
@OctavianDamiean Admob and getting on there and registered
 
9:26 AM
@Glitch The yellow line that overlays the text. It should not be overlaying it.
Other than that it looks very good.
I have no idea what that compatibility list is all about but it looks good.
 
@Glitch I would say the yellow should be flush against the ListView (or otherwise if it's not scrolly)
But yeah, damn sexy
 
Yeah the line is supposed to be below the text, but for some reason it's refusing to comply
 
Beat it up.
Take a tuna and ... well you know the rest.
 
I eat tuna for breakfast...
:P
 
You are not supposed to eat it. Use it to beat someone up.
 
9:31 AM
What a waste of perfectly tasty tuna...
I found the issue
The font...
CURSE YOU ANDROID!!!!!11111oneoneone
 
:/
You just pushed the line down a few pixels.
 
@Glitch
Can't find it :/
 
@OctavianDamiean pushing it down is difficult when you have to make sure everything lines up :P
 
If you can tell me where <public id="0x010301b4" name="TextAppearance.DeviceDefault.Small.Inverse" type="style"/> links to, I'll tell you though
 
O_o
 
9:38 AM
@Glitch Just put the Text and the Line in a Frame layout and layer it that way?
 
Oh wow, that looks pretty hackish.
 
Nah, you know why you put something like "?android:attr/textAppearanceSmall" in as an attribute
Those are linked up via ID's
as above.
I just can't figure out where those ID's then link to define the attributes.
Once I know that, it'll be easy to link it all up
 
I thought IDs were auto generated?
 
And i can tell you how to globally do your own text font's n shit.
 
They are.
 
9:41 AM
Not in the android core stuff. They don't need to be regenerated since they are constant per release.
 
Oh there.
 
I hate when you follow a peice of string from functionality to functionality until it hit's a solid brick wall with no features or opening's so you can't see where the hell it went. Probably coded up in a class somewhere.
 
search the ID in google code?
 
That's what I'm doing now :) Just going to unhex that number
Er.. little help in unhexing that number?
 
16974260
 
9:45 AM
Not sure why you'd want unhex it.
 
Got it
@OctavianDamiean That's how it would be written in the R.java file
Well, not the R file, but in a file somewhere since it's a constant.
 
Java is stupid ... I need some pain killers.
 
Damn you Android, just tell me what you're hiding!
I know it's a reference damnit, a reference to what!? WHAT?!!?
 
It is in frameworks/base/core/res/res/values/public.xml
 
I know, that's where I got it from :)
 
9:50 AM
Oh.
 
why is the Android fastScroll thumb thingo so friggin ugly?
Hmm, I need to figure out how to use AlphabetIndexer with an arraylist
 
10:09 AM
Heck ... I'm gonna grep the entire damn source code now.
 
@OctavianDamiean Got you curious? :)
 
Yup. :P
 
I'll leave you to it - i'm supposed to be getting stuff done!
Can someone check my eyes for me please
True or false, "SimpleOnGestureListener" does nothing... Right?
All it's methods just return.
 
yep
you have to override the functions you want
 
Great - So why is "onFling()" flinging since all my code does is call super().onFling() ?
grumbles
 
10:24 AM
sure you're using SimpleOnGestureListener?
 
Yeah, sorry, if i wasn't handling the gesture was passing it down the chain.
Forgot that I'm not actually controlling the Scrolling Action, only the Overscroll color effect :)
Which means that there is a bug in the default onFling() which is interesting...
 
Looking through my code, you can clearly see my learning process :P
From ultra terrible code to clean code... a 7 month timeline of struggle. :P
 
nods
I still find that with mine
Feels very good to wipe out old convoluted code and replace it with sleek "obvious" code which takes you an hour or two.
 
10:40 AM
indeed
will have to do that one day
fortunately, as ugly as it is, I was smart enough to maintain a decent interface
 
I just look at my old, horrible code... and replace it... with a new horrible code
lol
 
I do that too :P
Or, I add a lengthy comment which points out why it's so shit, and then never bother to do anything about it. :P
 
o.O
Really? You don't rip it out and replace it?
My app is soooooo sexy behind the scenes.
4
There isn't a bit of it I'm not happy with
 
Some of these methods are very nasty to implement
 
Well, alright, the keyboard pisses me off.
 
10:45 AM
I think I have the worlds most complex brightness app
39 classes...
Not trivial classes either
 
Oh, you were saying you find refactoring hard didn't you
 
just a curiosity.... any of you guys making money out of Android ?
 
@Glitch Is practically a millionaire
 
I'd agree if there were chicks in here to impress :P
 
You could impress me eyebrow flutter
Damnit it's still fricking bouncing.
 
10:48 AM
lol
 
But you're the one that made the lie up! :P
 
Created an entire new project to test it and it's still frigging bouncing dog rammit!
@Glitch Oh yeah...
 
You must be easy to impress. Say, look at this magic trick... takes wallet
...and that's how I became a millionaire, kids.
 
I thought it was the Lux market sales.
 
I've only sold 900 copies
 
10:50 AM
900!!
 
@Glitch what app ? link ?
 
I got my copy for free :D
 
That is 666 €!
 
Damn freeloaders :P
 
10:51 AM
SATAN!
 
All I had to do was hang out in this room and look useful.
 
@OctavianDamiean lucky I'm in Australia then :P
Our currency isn't satanic.
 
@Glitch very nice looking app
 
What are your experiences selling in the Android market? Can you actually make money from a niece app, or do you need to make one of the mainstream top apps in order to earn "decent" money?
 
It needs to be mainstream. My app may look profitable, but that's 7 months of work...
 
10:53 AM
@bjarkef That is pretty much exactly what we are discussing. Scroll up a bit.
 
Niece app o________________o
 
It looks nicer now, I need to update the screenshots
 
@Octavian: Oh, okay, (/me goes to read the log...) :)
 
May need to make a nephew app too :P
 
Actually, I've got an app in the market with ads in it... and I've gained so far 60$....
mega waste of time
 
10:55 AM
I considered putting ads, but they just piss people off
 
Right, that means that you can definitely pay me some money for my hard work making Lux good.
 
I still owe myself $50,000 for labour :P
 
Do you imagine how heavy such a tuna is?
 
I'll take unicorn hair as compensation
 
10:56 AM
Do pubes count?
Unicorn ones, that is.
 
@Glitch in my country... google checkout is not supported...
 
@Alin ahh, that sucks
 
Sif it be Unicorn ones.
 
No , just from the mane please.
 
How about some unicorn approved music?
 
10:58 AM
@Glitch I've made some really nice ads, full screen only when switching games... very non-intrusive... But hey.. at least I learned to use SurfaceView
 
People hate ads full stop. As soon as they see them they get offended.
 
Everyone else in the office has gone for secret santa in the kitchen
I voted out so I'm doing facebook until their back!
 
Ewwwwww
 
Facebook? Ewwwww!
 
11:01 AM
Why would a Unicorn ever approve something that has dead in its name?
 
Because they're dead awesome.
 
 
O.O
 
Goddamn capitalists.
 
Don't look @OctavianDamiean!
 
11:04 AM
... taking a slice of bread... hungry....
 
Too late, he's on the floor crying in the foetal position.
 
Oh crap, bricked my phone..
undo! UNDO!
 
Crap, er,
What do you do when you phone freezes and won't even turn off...?
 
Pull the battery out
 
11:05 AM
Take out the battery.
 
wash it
 
Hold power button for 10 seconds
 
We have a winner. @Reno :D
 
Take a WP7 or iPhone
 
Ah, pulling out USB made it hard reset.
 
11:05 AM
@Alin He already bricked his phone, no need to find another brick!
 
A wet sponge and everything will be good.
 
I feel sorry for those with internal batteries...
 
They can still throw the phone against a wall to open it up.
So they either go with the P2B or B2P method.
 
I only know of Android phones to require battery pull because of freezes....
 
You know why Motorola named their phone the Razr? Because you want to cut yourself every time you try to use it.
@Alin Probably because we keep doing shit to our phones that you can't do on other devices.
 
11:09 AM
@Alin Believe everything Glitch said right now because he knows exactly what he is talking about!
His Lux features are really that amazing. :P
 
I can brick phones like a pro
 
You sure do. :P
 
@Glitch android requires a lot of shit to do... to make simple things... like a bloody animation
 
I brick phones and get paid for it.
 
Damn you Reno! :P
 
11:10 AM
@Reno so do I, apparently :P
 
hee hee, I like this room XD
Hi @Glitch! Perth is fun ;D
 
The only difference is that people pay Glitch for bricking their phones. :P
 
Also, 'brick' one of your GN so I can have it :P
 
Anyone around willing to donate a Galaxy S 2 or a Galaxy Nexus ? :D You just get rid of all the freezes and shit android puts to
 
"Oh dear, it appears this phone is broken... I better send it to some random guy in Australia!"
I planned to write another app with a friend
 
11:13 AM
@ProfSmiles Let's talk again when people in here get tired and their mental level shrinks to the mental level of a cockroach.
 
@OctavianDamiean I agree. Too many silly people in here!
 
I'm of course one of them because I wouldn't want to miss that party.
Nice try Glitch, nice try. Trying to look normal and stuff ...
 
btw, is anyone bothering to natively support Android 4 yet? Because I like my TabView >:(
 
Soon-ish a book will be released that will show you that there are better ways than a TabView.
 
11:16 AM
Damn, the "bug in my code" isn't a bug in my code, it's a bug in Android's "OVER_SCROLL_NEVER" feature.
 
I'm one of the technical reviewers so it'll likely brick your phone trying but still.
 
I think after this coming update I'll just completely rewrite my app. I'll put Android3.x+ support in that :P
 
I still support 2.1 devices
 
Yea all my bugs are in fact bugs in Android.
 
As painful as that is..
All my bugs are brain farts
 
11:18 AM
@Glitch not as painful as still supporting 1.6. :D
 
If you're still running 1.6, you should probably furnish the rock you've been living under.
 
The compat libs can be added to 1.6+, IIRC
 
@OctavianDamiean ouch
my target SDK is 2.1 and that's how I'm coding, but for some reason the Menu button doesn't come up on my Transformer (3.2)
 
@Reno Yea but where is the fun developing with the compat lib?
Reinventing the wheel every time and stuff like that.
 
How do you do a bug report to the Android team?
 
11:20 AM
oh yeah .. b.android.com
 
I thought it was wedontcare.android.com
 
That is not right. They do care.
 
"We'll fix the bugs when we feel like it! (tm)"
:P
 
Ouh, gotta run, laters.
 
11:23 AM
I think the bug-fixing process is probably just a once a week,
[Python]
import random
import AndroidErrors # :P
print AndroidErrors.select(random.randint(0,AndroidErrors.number))
then it's probably "hhhmmm, can I fix this in <10 minutes?"
 
11:34 AM
@Glitch, you there?
 
@Veer indeed
 
Intent intent = new Intent(Gra.this, NowaGra.class);
startActivity(intent);
is this is only way to change the activity in Android?
@Glitch
 
what's wrong with that?
 
You shouldn't ping people, but I'll answer.
That is the only way I know.
 
Sorry for pinging,
Thanks for helping
@Glitch
 
11:37 AM
does anyone know if there's like an onFocusReceived for an activity? (eg. a tab in a TabView) so that I can check if a thing's changed and reload if necessary
 
What are the things that are changing?
 
in one tab you can add favourites to the DB, but going to the favourites tab hasn't got it until you reload it
 
is this a list of favorites?
 
yes(?) it's stored in a DB and shown in a ListView (?)
 
Couldn't you just call notifyDataSetChanged() when the tab is pressed?
 
11:41 AM
I shall look into that, cheers
 
Really you should call that as soon as you make the change
 
Is it favourites or favorites in Oz ?
 
The first one
I just spelt it wrong because the damn Americans!
(Protip: Always blame Americans)
 
(Y)
damn, I was hoping that'd be a thumbs up
 
Looks more like malformed boobs
 
11:44 AM
and I'm putting "Favourites" in my app even though when I geotrace the IP's of API calls, 99.99% of them are from the US or Canada
 
They can learn proper English
 
12:02 PM
so...... I've been looking around but, how do I use notifyDataSetChanged on a ListActivity from a different Activity? :/
 
Easy way would be to just call it when the activity starts
I need help
I want to compare two lists, each containing objects of different type
 
I doubt I can help but what's up? :P
 
I need a way to define a custom comparison (Comparator?) then when I find a match, add it to a third list
 
what are the types?
 
PackageInfo and String[]
Not that it matters, I know which parts I want to compare, I just need a way to do it :P
I guess a simple way of explaining what I want to do is, I want to 'cross check' the lists and pull out the elements that are in both
I'm hoping there's something in Collections that'll help
 
12:09 PM
well my friend, who's a Java nut, says "just iterate"
 
I agree, iterate ... but the technically correct way is the Comparator
 
iterating sounds expensive
 
"the best way to do it though
is to make sure both are the same type
then make a set
make them both sets of some base type
then Set.union
ALL IS WELL"
 
If I were to make them the same type, that'd involve a fair amount of object creation
I'd need to pull out strings from the PackageInfo
 
If the objects are not the same type you use a Comparator
 
12:12 PM
I suspected so, but is there an easy way to use that Comparator apart from manually iterating?
Iteration would be O(n*m) complexity
 
OK, here's our conversation:
ProfSmiles: and "iterating sounds expensive"
fullwall: yeah... that's because his code is shitty
fullwall: ok
fullwall: make a set from the String[]
fullwall: iterate the package info
fullwall: wait no
fullwall: ugh
fullwall: just tell him to fix his shit code
fullwall: it's going to be slow no matter what
 
Yep, my code is shitty... I kinda have to work with Android here
 
bahahaha
 
How does he propose this code become non-shitty?
 
12:16 PM
I said non-shitty, not 'good'. :P
@Reno Do you think I should make the PackageInfo List into a String[] list?
 
`No, it depends
just a sec
 
12:32 PM
10
Q: How Best to Compare Two Collections in Java and Act on Them?

sundae1888I have two collections of the same object, Collection<Foo> oldSet and Collection<Foo> newSet. The required logic is as follow: if foo is in(*) oldSet but not newSet, call doRemove(foo) else if foo is not in oldSet but in newSet, call doAdd(foo) else if foo is in both collections bu...

This is what I ended up using
Helpful ?
 
One curiosity... is there a way to know when a app is closed ? Rather then scanning regularly for open processes ?
 
onDestroy() ? :P
 
3rd party apps
for instance.... when closing the browser... detect and turn off wifi
just a random curiosity of mine
 
I wrote a stalking Service that does that
Yeah it scans every second though
 
@Reno holly macawolly
and it doesn't drain battery ?
 
12:39 PM
Nope ... I've optimized it to run only when a 3rd party app triggers GPS.
Now I've changed it to scan every 5 seconds
 
@Reno I'll take a look now, thanks
@Alin I have a service which checks for the active app every 2 seconds
There's no trivial way to do it :(
 
It depends, I adjust the frequency of the scan depending on the battery current/power
 
I thought this was the only way... nasty as android used us...
 
Comparing strings every 2 seconds isn't exactly battery intensive
 
No but asking for the process list is battery consuming
 
12:41 PM
just remember to turn it off when the screen is off
true
Android needs an intent for 'top app changed'
 
and you are using an AlarmManager for it, or timer ?
 
I did that ...
 
did what ?
 
Checking if the top app is changed. Damn my code is unreadable. >_>
 
But you have to poll, right?
 
12:45 PM
Basically it is this code with a lot of optimizations. Yeah you have to poll, I've made the polling adjustable though
 
I see
Mine polls every 2 seconds because I need to react fast
The user can turn it off though
 
@Reno thx for the post... reading... cursing... reading.... cursing android
 
@Reno that example you linked are lists of the same object type
 
gahh, I'm still battling with notifyDataSetChanged(). @Glitch what is it a method of?
 
It's a method of your list adapter
 
12:51 PM
so how can I call it from another Activity?
 
You don't have to, just call it the next time you return to the list.
 
@ProfSmiles anytime you alter the list that backs the adapter, you should call notifyDataSetChanged()
 
Perhaps make a flag called 'dataChanged' and your list can check that to see if it should call notifyDataSetChanged()
 
@JasonVinson well it's adding favourites to a DB from one activity, but going to the activity in the TabView that lists the favourites doesn't show the new favourite if it's already loaded
 
Is it poor form to use the Observer/Observable pattern in an android app?
sounds like that is what you are trying to do
 
12:57 PM
Here's a nice article if you haven't used ViewPager: blog.stylingandroid.com/archives/537
 
@ProfSmiles this doesn't seem like a difficult problem
when you add favorites to the DB, set a global flag 'dataChanged' to true. Next time you access the list, check the flag and if true, call notifyDataSetChanged();
 

« first day (431 days earlier)      last day (4527 days later) »