Android : Viewing App Features (MIME Types, Etc)?
Sep 28, 2010Is there any way (and preferably a pre-existing tool) to view the external features of an app, in particular the MIME types an activity supports?
View 5 RepliesIs there any way (and preferably a pre-existing tool) to view the external features of an app, in particular the MIME types an activity supports?
View 5 RepliesI can't seem to find out how a MIME type is found. For instance, say I want my application to bring up Contacts. Where can I find the MIME type for that task? I currently have the following:
Intent intent = new Intent(); intent.setAction(Intent.ACTION_GET_CONTENT); intent.setType("*/*");
Intent newIntent = Intent.createChooser(intent, null); startActivityForResult( newIntent , SHOW_VERIFY_ACTIVITY );
And the wildcards work. But I would like to be more explicit. Like the following:
intent.setType("vnd.android.cursor.item/contacts");
...but is not valid.
Is there a way to use setType() and supply multiple broad types (like images and video)?
I'm using an ACTION_GET_CONTENT. It seems to be working with just comma-separated types.
I've been grappling with an issue all day.
I am trying to create a program to deal with .torrent files that are clicked on and/or downloaded by the browser. Currently the downloader reports "Cannot download. the content being downloaded is not supported on the phone"
Im fairly sure this is doable as i recently encountered the same issue with pdf files untill i installed a pdf reader.
I would like to run my app when a file extention is selected (from web browser, file browser, mail, ... : from everywhere in Android)
So : can I have a clear example of Manifest/xml and Java code to handle, let's say "*.doc" ?
What should be done in my Manifest.xml How to get the filename and read it from the Java code (from an Activity)
Is anyone aware of options for S/MIME email support on Android? My company uses S/MIME for email encryption and it does not appear to be supported in the default mail client.
View 6 Replies View RelatedI would like to a mimetype to Android Web browser, to allow opening my application when a certain mime type file is downloaded by the web browser. Apparently, only media file's mime type can be supported by the web browser. Is it right? How can I do it?
View 5 Replies View RelatedMy app has two private file formats with distinctive extensions. How to I register their MIME types and associate them with file extensions? My understanding that then my app can be launched to handle a file. How is this done and how to extract the file path my app is launched to handle?
View 4 Replies View RelatedI would like to get the mime type of my local media file (3gpp , mp4, ...etc) if it is of video then i want to allocate a SurfaceView for it additionally otherwise i just use MediaPlayer to play it i have found opencore has provided some interface for that and used by mediascanner.cpp but it seems in android media framework it isnt so can i achieve this by using android media framework?
View 4 Replies View RelatedI kept my .apk file in my "apache" webserver at "Document root" path. This is the only file at Document Root . I had removed index.html file at this location. If I keep the index.html file then other files where not displayed if I open the URL i.e http://<ip_address> using a web browser Now from my Google phone browser I'm able to download the apk file and and install it in Google phone. Note 1: I had not done any settings to add the MIME type "application/ vnd.android.package-archive" in apache web server. Note 2: I was connecting to my webserver through WiFi. But the same apk file I was not able to download from my Gmail (as attachment) and I got "unknown file type" error in this case. After reading few related topics, I came to know about the MIME type support required in webserver for android applications. Now I'm wondering how come file gets installed sucessfully from my apache webserver even without adding the MIME type "application/ vnd.android.package-archive". Any clues what's happening here?
View 4 Replies View RelatedTrying to figure what's wrong with my codings. I followed a blog post from here. I managed to get the codes to actually upload the file to a PHP web service. However, for some reason although I've set explicitly the MIME type for the file, PHP shows that the MIME is just a blank string and therefore rejected.
View 2 Replies View RelatedI want to register my application for files of a certain popular and well-documented MIME-type. The problem is that Android does not seem to recognize this MIME-type. The following sample code demonstrates this:
package com.example.helloandroid;
import android.app.Activity; import android.os.Bundle; import android.util.Log; import android.widget.TextView;
public class HelloAndroid extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); TextView tv = new TextView(this); tv.setText("Hello, Android"); setContentView(tv); String extn = android.webkit.MimeTypeMap.getFileExtensionFromUrl("/data/a.xyz"); String xyzMimeType = android.webkit.MimeTypeMap.getSingleton().getMimeTypeFromExtension (extn); Log.d ("HelloAndroid", "extn: " + extn + " | xyzMimeType: " + xyzMimeType); }
}
I made the connection between my service WCF and my app android. But i'm wondering if u have ideas about using complex types (classes created on the server side). should i implement the serialization process? or should i juts create the classes on my client side(android)
View 8 Replies View RelatedWe can launch the app in two ways, 1 is form the app, clicking on device back button till we reach the android home screen and launching the app or 2nd is from the app we can click the device home button and then we can launch.
How can we differentiate these to launches? In 2nd type launch onrestart will be called, onrestart will be called in some other cases also. I want to do something in the 2nd type of launch. Can any one tel me how to do this...
http://androidplayground.net/web/
they have been spamming the market all day, hope someone can get them shut down.
I'm trying to make a ListView when every item in that list can be a different type of View. for example the list could be: 1. TextView 2. ImageView 3. MyCustomView
I understands that in order to make a list I need to use an Adapter. the problem is that the Adapter uses a single layout for all of the list items, which will not support the different views.
my goal is to make an abstract View list when I can dynamically add and removes items in that list (each item is a View or subclass of it).
I've been working with Android for well over a year now, but I still have trouble determining when different types of messaging/communication between processes/threads should be used. I'm mainly talking about broadcasting Intents, using AIDL for services, using Handlers to send messages and socket communication.
Many of these tools can be used to accomplish similar tasks, but which is better suited to particular situations?
just wondering if anyone else here ever has this issue and if theres something to fix it? im using swiftkey and sometimes it just decides to go nuts and types a letter 2 or 3 times even though i only hit it once and then the word suggest screws up and also when i hit the spacebar once it goes nuts and puts in a period and starts a new sentance.
View 2 Replies View RelatedI want to implement a generic, thread save class which takes the RessourceId of an ImageView and the Url (http) where the desired image file is stored. It'll download the image and fills the src of the ImageView in the UiThread.
I thought AsyncTask would be the best thing for me. However I noticed that I only can pass one type of parameters to the doInBackground() Method. Like an Array of Urls. Is that true? What would u suggest me?
I have a weird issue, I have a Bluetooth speaker that I used for music on my Blackberry Storm, the storm automatically recognized that the speaker was a speaker, but the droid recognizes it as headphones, which is an issue, because the speakers are a2dp, and it's using the headset profile, which makes the sound quality SUCK!
Anyone have any idea how I can change it? I've tried unpairing and repairing it like 3 times now...
In a list, is it possible to have different kind of views, inflated from different layout XML?
I started with the sample in the API Demo, using the Efficient Adapter, and it starts like this Code...
When changing the custom locale the label of the phone types change to the appropriate language. Does anybody know how to get the localized label of the phone types?
I pick a contact in my app to get its phone number and if there is more then one number I use an AlertDialog to let the user select the currect one. In this pick list, I want to show the label of the type, so it's easier for the user to select. Since they labels are somewhere in the Android system, it must be possible to get the localized label. Unfortunately, the Phone.LABEL is null when reading the phone number.
ViewHolder pattern improves ListView scrolling framerate, as seen in following example:
http://developer.android.com/intl/de/resources/samples/ApiDemos/src/com/example/android/apis/view/List14.html
Is it possible to keep this pattern while using different kind of Views for different rows?
In other words, is it possible to do something like:
public View getView(int position, View view, ViewGroup parent) {
// calculate viewID here
if (view == null || *view is not null but was created from different XML than viewID* ) {
view = mInflater.inflate(viewId, null);
Is there a way to launch a viewer for common file types like TXT, DOC, XLS, PDF from within an app, like Gmail does. Maybe a Google Docs api to pass the file to GD and have it open in the browser?
View 2 Replies View RelatedIn the scenario that I made up a user chooses an application and and I offer him/her the available pieces of data to operate on. I know that the possible data type for an application is specified in its manifest file and I suppose that this information is available, but I have some difficulty finding out what the data content type for application is?
View 2 Replies View RelatedThere are a number of network types defined in TelephonyManager:
NETWORK_TYPE_GPRS
NETWORK_TYPE_EDGE
NETWORK_TYPE_UMTS
NETWORK_TYPE_CDMA
NETWORK_TYPE_EVDO_0
NETWORK_TYPE_EVDO_A
NETWORK_TYPE_1xRTT
NETWORK_TYPE_HSDPA
NETWORK_TYPE_HSUPA
NETWORK_TYPE_HSPA
Is there any info out there that describes what range of speeds you can expect on each of these? If that isn't available, it would be nice to be able to order them based on speed.
I know this may be a dumb question, but my background is more in c++ and managing my own memory.
I am currently cutting down every single allocation that I can from one of my games to try and reduce the frequency of garbage collection and perceived "lag", so for every variable that I create that is an Object (String for example) I am making sure that I create it before hand in my constructor and not create temporary variables in simple 10 line functions... (I hope that makes sense)
Anyways I was working though it some more tonight and I realized that I a may be completely wrong about my assumption on garbage collection and primitive types (int, boolean, float) are these primitive type variables that I create in a 10 line function that gets called 20 times a second adding to my problem of garbage collection?
I'm using JB 1.4.2 on Razr i. There's one thing that's annoying me a lot. I've installed the SNES Emulator SuperGNES and I've found that every single file type that have no app associated is showing SuperGNES icon and associated with it. Example: .log, .db, etc. Even files that have no extension is associated with it. The same problem occur when ZArchiver is installed. I don't know if it's a bug of these two apps or Android's in general. Remembering that this associations are shown only inside Android's native file manager. It's like every "unknown MIME type file" act like being the same.
View 6 Replies View RelatedAre following touch events supported by android platform or we have to implement them?
Touch event - Used to focus an item Tap - Execute action when finger is released Tap and hold - Long tap for some timeout Double tap - Tap twice without much delay Flick - Touch, hold, move and release quick Drag n drop - Touch, hold and drag Touch and move - Touch, hold, move and release in straight line
I"m planning to store my data in a binary format as a resource, read it into an int buffer and basically pass it straight down to a native C++ function, which might cast it to a struct/class and work with it. No pointers, obviously, just ints and floats. The question is - what kind of fixing up do I need to do? I suppose that I need to check ByteOrder.nativeOrder(), figure out if it's big Indian or little Indian, and perform byte-swapping if need be. Other than that, floats are presumably guaranteed to be expected in IEEE 754 format? Are there any other caveats I'm completely overlooking here? (Also - since I'm compiling using the NDK, I know what architecture it is already (ARMv7-A, in my case), so can I technically skip the Indian shenanigans and just take the data the way it is?)
View 1 Replies View Related