I'm learning how to program for the android market. Currently I'm using WebView to load a webpage stored on my host.
But I have noticed that It's really slow and everytime I change the orientation the whole page reloads instead of re sizing, making everything slow. Does anyone know how to make this work faster?
onResume is called on orientation change, check your code there.
You could also add android:configChanges="orientation" to your activity in the androidmanifest.xml to tell android that your app will handle orientation changes yourself.
Only "onConfigurationChanged" will be called then.
Without seeing the code its difficult to help improve it.
Related
applications are not running in the background
it stops when the screen locks
when it opens again it reloads and shows resuming
is there any way to run the application even when it is locked
Apps have to be recompiled for mango before they can use the benefits of mango. The market place will begin accepting such apps later this month. Also not all apps will "run" in the background. They have to be specifically coded to do background tasks. However apps may benefit from fast resuming which at face level it might appear the app is running but really it was dehydrated.
dont think its possible with current apps
Yeah theres a video on wmpu that goes for about 20 minutes where a guy from the windows phone 7 team discusses multitasking in depth. He pretty much says the last 5 apps you have used will not need to "resume" but will jump straight back in. Background task using apps that will give you toasts, live tiles etc can run an agent for 30 seconds every 30 minutes so battery is not used up.
Something else thats very good is in the settings you can choose to disable specific agents that you dont want the app in question to use, and then the app cannot force it back on, so you wont get annoying toasts etc from apps you dont want.
http://wmpoweruser.com/page/2/
I think its the 3rd video down
sambaman009 said:
Yeah theres a video on wmpu that goes for about 20 minutes where a guy from the windows phone 7 team discusses multitasking in depth. He pretty much says the last 5 apps you have used will not need to "resume" but will jump straight back in. Background task using apps that will give you toasts, live tiles etc can run an agent for 30 seconds every 30 minutes so battery is not used up.
Something else thats very good is in the settings you can choose to disable specific agents that you dont want the app in question to use, and then the app cannot force it back on, so you wont get annoying toasts etc from apps you dont want.
http://wmpoweruser.com/page/2/
I think its the 3rd video down
Click to expand...
Click to collapse
i dont think current apps can do this,correct me..
it needs mango specific apps?
Magpir said:
i dont think current apps can do this,correct me..
it needs mango specific apps?
Click to expand...
Click to collapse
Apps need to be recompiled with the Mango dev tools and resubmitted to the Marketplace, but the Marketplace is not accepting Mango submissions yet, so there are no applications on the Marketplace that support Mango multitasking at the moment.
i got a feeling the multi tasking isnt the same in mango beta as in the final version.
ok, seems the official wp7's multitasking is a crap - if I need to get the real background execution (constant socket listener), I cannot do this even with dehydration hack
but can I perform such background processing in an unmanaged code, through interop service?
Is there a way to use wifi in background cuz he turns off with screen? Anyone know for some fixes? I use Mango. -.-
@author:
if you developer, use this code lines:
Microsoft.Phone.Shell.PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled; // disable screenlock
Microsoft.Phone.Shell.PhoneApplicationService.Current.ApplicationIdleDetectionMode = IdleDetectionMode.Disabled; // disable to diactivate application
Click to expand...
Click to collapse
its works only with Mango.
Looking for a way to pass variable or setting to an app when it starts. In particular the camera, for instance if I want to shoot a lower res image without going through 4 screens to change it.
Searched this forum and androidcentral and google, nothing helpful found. there were a couple of posts asking how to send a variable to an app but...
I guess it would be similar to a command line entry in practice like
camera -res:640 -flashn
or camera -res:3264 -macro
(I just made these up cuz I also can't find the variable/settings for the camera)
A one touch button on the home screen for this would be ideal, also with an automatic "snap" for a picture kinda like the spycam apps that are available.
Thanks!
Not sure, but Tasker might do that find it in the market then visit the devs site for free 7 day trial
CM7, Nightly. Captivate
I've got tasker installed already and can make it do basic stuff. The user guide doesn't tell how to pass a variable to a program when it starts.
I suppose I would also need to know what variables the camera app is expecting to see.
I'm not sure how to handle this, but it's driving me batty! I have a Kindle Fire running Apex Launcher on Hashcode's Cyanogen. I love Chrome but for some reason they didn't include an option to simply open the browser with NO pages. I find myself constantly closing prior pages I've opened before. I'd like to start Chrome up with no pages open (for speed sake).
Not sure if there is some work around that can be done. I tried using Apex to run a single instance of chrome, but this also disables a LOT (not sure what that thread call is used for I guess). I've attempted to locate any command line flags, but doesn't seem Chrome has any or I just don't know what the term is to do a proper web hunt for the info.
You can speak techy to me, I generally can do just about anything to the device.
I've since found the file /data/local/chrome-command-file, but I haven't stumbled upon an option yet that actually works (for this issue, or even as a true to life toggle for chrome android app)
I've tried the following:
--homepage
--disable-sync-tabs
--disable-restore-session-state
--disable-session-storage
--single-instance
--chrome-frame --kiosk
--kiosk
--new-window
I have permissions on the file set correctly (755), it just doesn't seem to be reading the file? Or maybe the android version doesn't have nearly any of the options the Chromium version does?
Hello folks, Friend of mine who is blind has gone from iphone to android. They have an App they are attempting to use that came with a smart cooker, but there is one single aspect of the app that is hindering the usefulness. It is a Picker that comes up to set duration, Talkback just doesn't want to see it. So I i was thinking If I could decompile the app maybe I could somehow muddle my way into making it accessible. LOL... I got it de-compiled, looked over the XML's and JAVA and bam I'm lost. Now I am not asking for anyone to hold my hand or do this for me. But I was hoping someone might give me an idea of where to focus to make a change like this, From there maybe I can figure it out for future issues. At this point I am not even sure If I need to focus on change to an XML file or the JAVA itself. Any help would be awesome.
CLJNCO said:
Hello folks, Friend of mine who is blind has gone from iphone to android. They have an App they are attempting to use that came with a smart cooker, but there is one single aspect of the app that is hindering the usefulness. It is a Picker that comes up to set duration, Talkback just doesn't want to see it. So I i was thinking If I could decompile the app maybe I could somehow muddle my way into making it accessible. LOL... I got it de-compiled, looked over the XML's and JAVA and bam I'm lost. Now I am not asking for anyone to hold my hand or do this for me. But I was hoping someone might give me an idea of where to focus to make a change like this, From there maybe I can figure it out for future issues. At this point I am not even sure If I need to focus on change to an XML file or the JAVA itself. Any help would be awesome.
Click to expand...
Click to collapse
Not sure if the problem still exists, but there is a couple of things to look at.
First, check what Java class is used to render the Picker.
If it's a part of Android framework, check Stackoverflow to see if it has accessibility issues.
If it's an external class, you will need to modify it to expose it to Accessibility API.
For supported built-in views check XML files for android:contentDescription attributes.
Hi all. It seems like there's a lot of people annoyed by ads on Instagram. I was, too, until I figured out a novel way to patch it.
Changes
Removed ads in the feed.
Removed ads in stories.
Removed "who to follow" blocks in the feed.
Removed stories in the feed (those between the posts, not those on top of course).
Carousel posts always show the first media instead of randomly jumping to the second one.
Analytics requests are blocked.
Enabled "internal" settings, accessible by either long-pressing the home tab or in the settings menu. These allow doing a lot, so use with care. The most useful feature so far is the ability to manually override each of the gazillion server-side configuration values.
Without further ado, here's the link: Download.
How my patch works
Instagram, as, probably, all the other Facebook apps, uses Proxygen for its HTTP client. Since Proxygen is written in C++, it needs JNI bindings to be used in an Android app. This means that the Java classes that interface with the native code can't be obfuscated. So, instead of digging through piles of obfuscated code that gets reshuffled with each update, I did the most straightforward thing: I injected my code into Proxygen's Java part. I had to make minimal modifications to the bytecode in order to intercept the API responses and pass them through my code before the app gets any chance to process them.
To repeat the process yourself:
Download any Instagram apk or pull one from your device.
Run apktool d on it.
Download View attachment 4752809 and unpack it. Place the two files into smail/com/facebook/proxygen in your disassembled Instagram folder, replacing the existing ones.
Download View attachment 4842971, unpack it and place the folder into any of the smali folders; I did smali_classes3 because there was no room for method references in the first dex.
Build the new apk with apktool b.
Sign it.
Install it.
Enjoy!
The sources for the hooks are in View attachment 4842969. You compile these with javac, then run dx to convert them to dex, then baksmali to get the smali files that apktool can then integrate into Instagram's dex.
Unlocking the developer settings is another thing entirely as it doesn't depend on the API. There's no getting around the obfuscated code. You need to find an enum class that has RELEASE, DEBUG, INHOUSE as its values. There are several methods that return boolean; you need to change the one that returns true to false (this determines whether this is a release build), and then another one to return true so that the build type returned ends up as INHOUSE. Decompiling it using jadx makes figuring this out a lot easier.
I'll probably automate the patching process at some point in the future.
Hope you enjoy!
13/10/2019: updated to v114 and updated hooks files.
App seems to crash when I access my following list by going to my profile. Running Android Pie.
Ac3Da3m0n said:
App seems to crash when I access my following list by going to my profile. Running Android Pie.
Click to expand...
Click to collapse
I can confirm this. App crashes when I open my following and followers list, and when I open my "viewed by" stories list.
Enviado de meu Redmi Note 5 usando o Tapatalk
I'll test on my Xiaomi Redmi Note 6 Pro
Can I download pics with this Mods?
el_easy said:
Can I download pics with this Mods?
Click to expand...
Click to collapse
No. It's not modded Instagram app.
Crashes on following/followers list
And on multiple logins also
el_easy said:
Can I download pics with this Mods?
Click to expand...
Click to collapse
No. This doesn't touch any of the UI because I aim for it to be as portable between versions as possible. To modify the UI you inevitably have to touch obfuscated code.
These crashes are caused by apktool not decoding resources properly. I created an issue on github.
Great work. On the most part, ads are blocked. However, branded content shows up in the feed sometimes. I think there's an internal setting called "branded content show settings" not sure if this is the right option.
Also has anyone figured out which internal flag switches the feed back to a linear post history instead of the personalized one?
Edit:
To those who can't seem to install the apk, you have to disable Play Protect in the Google Play Store as that is blocking apps with an unknown signature from being installed.
There are some crashes when I tweaking settings, otherwise good mod.
Great work, thanks
I can confirm it crashes when trying to open the followers list
@Grishka11, for many people its crashing including me. Can you upload a patched version so that its easier for everyone to just install the apk?
Grishka11 said:
No. This doesn't touch any of the UI because I aim for it to be as portable between versions as possible. To modify the UI you inevitably have to touch obfuscated code.
Click to expand...
Click to collapse
Thanks bro, I will wait for the next version because the crashes ...
By the way, I hope one day you can do the same with Facebook app, I know evilwomba does that, but he takes too long to update..
pratik_193 said:
@Grishka11, for many people its crashing including me. Can you upload a patched version so that its easier for everyone to just install the apk?
Click to expand...
Click to collapse
What do you mean? This is a patched version. There's a bug in apktool that causes it to crash because of the non-standard way the resources are stored in the original apk to reduce its size.
el_easy said:
Thanks bro, I will wait for the next version because the crashes ...
By the way, I hope one day you can do the same with Facebook app, I know evilwomba does that, but he takes too long to update..
Click to expand...
Click to collapse
I mainly patched Instagram because I use it myself a lot. Facebook isn't a thing where I'm from, so I don't even have the app installed, I use the mobile website on the rare occasions when I need it. I can try, of course...
Great work and pretty interesting approach. Keep it up!
Grishka11 said:
What do you mean? This is a patched version. There's a bug in apktool that causes it to crash because of the non-standard way the resources are stored in the original apk to reduce its size.
Click to expand...
Click to collapse
You are right. The mod is amazing! It was getting very annoying to see ad after every 2nd or 3rd post on insta.
Any news about a possible fix?
nicknitewolf said:
Great work. On the most part, ads are blocked. However, branded content shows up in the feed sometimes. I think there's an internal setting called "branded content show settings" not sure if this is the right option.
Also has anyone figured out which internal flag switches the feed back to a linear post history instead of the personalized one?
Edit:
To those who can't seem to install the apk, you have to disable Play Protect in the Google Play Store as that is blocking apps with an unknown signature from being installed.
Click to expand...
Click to collapse
confirmed about sponsored post shows up sometimes.
keep up the good work!