Saturday, May 11, 2013

[General] sound problem after update, PLEASE HELP!


I have htc desire x, i got this phone 4 days ago... I loved the sound in my music player, its just so loud and thats really important to me!
But today i got a new update notification and i decided to update it. To be precise its update: 2.20.401.5.
So after this update everything is just wrong. The main problem is beats audio now doesn't work when playing music without headphones. The sound is terrible. Also the main music player is really messed up... i click on one song and it starts the other one. I have beats audio option to turn off and on now in the settings, which i didnt have before. And i can only turn it on with heaphones plugged in. Before this update the sound was very good and loud and now it's just sad
I was searching the internet for 2 hours now and i usually found the solution that way... but not this time. So this is my last option now to ask here. I hope you can give me some good advice.
I already tried factory reset and it did nothing. The software version is still the same. I wish i could somehow go back to the old version or install a complete new one. Im never updating again -.-



.

forum.xda-developers.com

[General] Cant use / find apps


Hi

Since getting the S4, i have downloaded a few apps from the Play Store, but cannot find them on the phone itself. I went to the help section and followed the instructions and sure enough, it lists the apps and states they are 'installed'. Yet when i go into the apps section on the phone, they are nowhere to be seen. Also, after i have downloaded each one, a Play Store icon appears at the top, can someone tell me what that is??

Thanks



.

forum.xda-developers.com

[General] How to Recover Deleted Contacts from Samsung Galaxy?


There are not many software that can help to recover contacts from Samsung Galaxy, but don't worry. There is still one, and it's enough to rescue your lost contacts on Samsung Galaxy. It's Wondershare . You can use it to recover deleted contacts directly from Samsung Galaxy, as well as messages, photos and video. In order to get the greatest chance to find your lost contacts, you'd better not use your phone for anything since the data loss.



.

forum.xda-developers.com

[General] How to Recover Deleted Data from Samsung Epic 4G Touch?


Don't worry. You still have a chance to get them back, but you need to keep this in mind: Stop using the device to take new photos or videos, text messages or make calls after you lost data. It will ensure you a better chance to recover them. Then find a Samsung Android data recovery program to recover them ASAP.

Before you do anything else, download and install a reliable photo recovery program on your computer: Wondershare , trustworthy and professional software. You can use it to recover deleted pictures, video, contacts and messages.



.

forum.xda-developers.com

[General] How to recover Data from Samsung Infuse (Including SMS, Contacts, Photos & Video)


The answer is YES. If you didn't capture new photos, text messages, make calls with/on your Samsung Infuse, there is a good chance that you'll retrieve deleted photos from Samsung Infuse phones, for new data can overwrite your previously deleted one and make it unrecoverable.
How to recover deleted photos from Samsung Infuse

First, get a digital cable that can connect your phone to the computer well. Then find a photo recovery tool, download and install it on your computer. If you still don't have one, here's my recommendation: , which is professional and trustworthy. You can use it to recover deleted messages, contacts, photos and video from Samsung Infuse in 3 steps with ease.



.

forum.xda-developers.com

[General] How to Recover Contacts, SMS, Photos & Video from Samsung Galaxy Note


Samsung Galaxy Note family is a popular product currently. Imagine you have taken important photos and make videos on your Galaxy Note 1/2/3, etc. However, you are still at a higher risk of losing them any time. Data loss issue might happen if you store your videos, photos for a long time on the phone without transferring them. The good news is that you can still recover your lost messages, contacts, photos and video from your Galaxy Note.

Wondershare Dr.Fone for Android is a comprehensive program for you to fulfill the Galaxy Note data recovery process. It enables you to recover lost or deleted files from Galaxy Note family devices with ease, including messages, contacts, photos and video. What’s even better, you can get a trial version to check and preview your lost files before recovery



.

forum.xda-developers.com

[android help] Mediaplayer track change issue


This is my code to play and update Track and on a button click I call the update() function but the track doesn't change properly.


First track plays just fine but when I try to switch to the next then it behaves improperly where am I wrong.



MediaPlayer mPlayer;


@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
mPlayer=new MediaPlayer();
mPlayer.setOnPreparedListener(this);
}

public void prepareMediaPlayer(FileDescriptor fd)
{
try {
mPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);
Log.d("player", "setAudiotStreamType");
mPlayer.setDataSource(fd);
Log.d("player", "setDataSource");
mPlayer.prepareAsync();
Log.d("player", "prepareAsync");

}
catch (IOException e) {}
catch (IllegalArgumentException e) {}
catch (IllegalStateException e) {}
}

@Override
public void onPrepared(MediaPlayer arg0) {
}

public void updateTrack()
{
File f=(File) imageFilexxSm.values().toArray()[index];
FileInputStream inputStream = new FileInputStream(f);
prepareMediaPlayer(inputStream.getFD());
inputStream.close();

if(mPlayer.isPlaying())
{
mPlayer.stop();
mPlayer.reset();
mPlayer.reset();
}

else
{
mPlayer.start();
}

}


Log:



05-11 13:17:42.782: E/MediaPlayer(14969): start called in state 4
05-11 13:17:42.782: E/MediaPlayer(14969): error (-38, 0)
05-11 13:17:42.821: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.372MB for 4194320-byte allocation
05-11 13:17:43.040: I/System.out(14969): index value is 0/1024/0
05-11 13:17:43.087: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.457MB for 2261008-byte allocation
05-11 13:17:43.189: E/MediaPlayer(14969): attachNewPlayer called in state 8
05-11 13:17:43.220: I/Choreographer(14969): Skipped 35 frames! The application may be doing too much work on its main thread.
05-11 13:17:43.275: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.452MB for 4194320-byte allocation
05-11 13:17:43.392: I/MediaPlayer(14969): Don't send intent. msg.arg1 = 0, msg.arg2 = 0
05-11 13:17:43.392: E/MediaPlayer(14969): Error (-38,0)
05-11 13:17:57.642: I/System.out(14969): action down
05-11 13:17:57.642: I/System.out(14969): points 1.6014493?21
05-11 13:17:57.642: I/System.out(14969): show one page
05-11 13:17:57.642: I/System.out(14969): start curl right
05-11 13:17:57.650: I/System.out(14969): index value is 1/1024/1
05-11 13:17:57.681: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.401MB for 2261008-byte allocation
05-11 13:17:57.775: E/MediaPlayer(14969): attachNewPlayer called in state 128
05-11 13:17:57.821: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.401MB for 4194320-byte allocation
05-11 13:18:04.704: I/System.out(14969): action down
05-11 13:18:04.704: I/System.out(14969): points 1.692029?21
05-11 13:18:04.704: I/System.out(14969): show one page
05-11 13:18:04.704: I/System.out(14969): start curl right
05-11 13:18:04.704: I/System.out(14969): index value is 2/1024/2
05-11 13:18:04.736: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.315MB for 2261008-byte allocation
05-11 13:18:04.829: E/MediaPlayer(14969): attachNewPlayer called in state 128
05-11 13:18:04.876: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.316MB for 4194320-byte allocation
05-11 13:18:08.845: I/System.out(14969): action down
05-11 13:18:08.845: I/System.out(14969): points 1.5471015?21
05-11 13:18:08.845: I/System.out(14969): show one page
05-11 13:18:08.845: I/System.out(14969): start curl right
05-11 13:18:08.845: I/System.out(14969): index value is 3/1024/3
05-11 13:18:08.876: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.316MB for 2261008-byte allocation
05-11 13:18:08.970: E/MediaPlayer(14969): attachNewPlayer called in state 16
05-11 13:18:09.025: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.316MB for 4194320-byte allocation
05-11 13:18:12.892: I/System.out(14969): action down
05-11 13:18:12.892: I/System.out(14969): points 1.5688405?21
05-11 13:18:12.892: I/System.out(14969): show one page
05-11 13:18:12.892: I/System.out(14969): start curl right
05-11 13:18:12.892: I/System.out(14969): index value is 4/1024/4
05-11 13:18:12.923: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.316MB for 2261008-byte allocation
05-11 13:18:13.025: E/MediaPlayer(14969): start called in state 4
05-11 13:18:13.025: E/MediaPlayer(14969): error (-38, 0)
05-11 13:18:13.064: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.316MB for 4194320-byte allocation
05-11 13:18:13.126: E/MediaPlayer(14969): Error (-38,0)
05-11 13:18:13.126: I/MediaPlayer(14969): Don't send intent. msg.arg1 = 0, msg.arg2 = 0
05-11 13:18:18.228: I/System.out(14969): action down
05-11 13:18:18.236: I/System.out(14969): points -1.5289855?21
05-11 13:18:18.236: I/System.out(14969): show one page
05-11 13:18:18.236: I/System.out(14969): index value is 3/1024/3
05-11 13:18:18.259: I/dalvikvm-heap(14969): Grow heap (frag case) to 30.316MB for 2261008-byte allocation
05-11 13:18:18.353: E/MediaPlayer(14969): attachNewPlayer called in state 8
05-11 13:18:18.400: I/dalvikvm-heap(14969): Grow heap (frag case) to 34.316MB for 4194320-byte allocation


.

stackoverflow.comm

[android help] Google Play Console unsupported devices (808)


I have just released a app on Google Play. It shows unsupported 808 devices out of which some are listed below for reference




MICROMAX A44– tinnoes13_s7050 A45– tinnoes73_s8030_2g P300– crane-M701C_mmx A73– A73 P275– P275




Also some testing on friends devices I realize that Android 4.0 devices, dont show the app on Google Play.


My Manifest file has the following. What am I missing here ? Is there a way to support "all" devices?



android:versionCode="10"
android:versionName="1.18" >
















android:maxSdkVersion="16"
android:minSdkVersion="8"
android:targetSdkVersion="16" />

android:anyDensity="true"
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true" />


I haven't mentioned the app since I dont want to violate SO's rules on self app promotion. If needed, I can mention it on a comment. Just request for it.



.

stackoverflow.comm

[android help] Android Development: Custom ListAdapter in Fragment


I got the following Fragment



public static class DummySectionFragment extends Fragment {

ListView msgList;
ArrayList details;
AdapterView.AdapterContextMenuInfo info;

public void addVertretung (String Fach, String Raum, String Farbe) {
StundenplanDetail Detail;
Detail = new StundenplanDetail();
Detail.setFach(Fach);
Detail.setRaum(Raum);
Detail.setFarbe(Farbe);
details.add(Detail);
}



/**
* The fragment argument representing the section number for this
* fragment.
*/

XMLParser parser = new XMLParser();
String xml = null;

public static final String ARG_SECTION_NUMBER = "section_number";

public void loadArray (String dayArray) {

}

public DummySectionFragment() {
}

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {

try{
byte[] inputBuffer = new byte[20000];
File inputFile = new File("sdcard/Android/data/com.approfi.woehlerschule/data.woehler");
FileInputStream fileInputStream = new FileInputStream(inputFile);
fileInputStream.read(inputBuffer);
xml = new String(inputBuffer);
fileInputStream.close();
}catch(IOException e){
Log.d("Fehler:", e.toString());
}


View rootView = inflater.inflate(
R.layout.fragment_stundenplan_dummy, container, false);


if(Integer.toString(getArguments().getInt(ARG_SECTION_NUMBER)).equals("1")){
int splitpos1 = xml.indexOf("");
int splitpos2 = xml.indexOf("
") + 9;

String xml2 = xml.substring(splitpos1, splitpos2);
org.w3c.dom.Document doc = parser.getDomElement(xml2);
NodeList nl = doc.getElementsByTagName("Stunde");


for (int i = 0; i < nl.getLength(); i++) {
Element e = (Element)nl.item(i);
String Fach = parser.getValue(e, "Fach"); // name child value
String Raum = parser.getValue(e, "Raum"); // cost child value
String Farbe = parser.getValue(e, "Farbe"); // description child value
Log.d("Fail:", Fach + Raum + Farbe);
}
}



/*if(Integer.toString(getArguments().getInt(ARG_SECTION_NUMBER)).equals("2")){
ListView listViewStundenplan = (ListView) rootView.findViewById(R.id.listViewStundenplan);
ArrayAdapter arrayAdapter = new ArrayAdapter(getActivity(), R.layout.list_item_stundenplan, dienstagArray);
listViewStundenplan.setAdapter(arrayAdapter);
}


if(Integer.toString(getArguments().getInt(ARG_SECTION_NUMBER)).equals("3")){
ListView listViewStundenplan = (ListView) rootView.findViewById(R.id.listViewStundenplan);
ArrayAdapter arrayAdapter = new ArrayAdapter(getActivity(), R.layout.list_item_stundenplan, mittwochArray);
listViewStundenplan.setAdapter(arrayAdapter);
}


if(Integer.toString(getArguments().getInt(ARG_SECTION_NUMBER)).equals("4")){
ListView listViewStundenplan = (ListView) rootView.findViewById(R.id.listViewStundenplan);
ArrayAdapter arrayAdapter = new ArrayAdapter(getActivity(), R.layout.list_item_stundenplan, donnerstagArray);
listViewStundenplan.setAdapter(arrayAdapter);
}


if(Integer.toString(getArguments().getInt(ARG_SECTION_NUMBER)).equals("5")){
ListView listViewStundenplan = (ListView) rootView.findViewById(R.id.listViewStundenplan);
ArrayAdapter arrayAdapter = new ArrayAdapter(getActivity(), R.layout.list_item_stundenplan, freitagArray);
listViewStundenplan.setAdapter(arrayAdapter);
}
*/


msgList = (ListView) rootView.findViewById(R.id.listViewStundenplan);

msgList.setAdapter(new StundenplanAdapter(details, this));


return rootView;
}
}


And that Adapter for my List View



public class StundenplanAdapter extends BaseAdapter {

private ArrayList _data;
Context _c;

StundenplanAdapter (ArrayList data, Context c){
_data = data;
_c = c;
}

public int getCount() {
return _data.size();
}

public Object getItem(int position) {
return _data.get(position);
}

public long getItemId(int position) {
return position;
}

public View getView(int position, View convertView, ViewGroup parent) {
View v = convertView;
if (v == null)
{
LayoutInflater vi = (LayoutInflater)_c.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
v = vi.inflate(R.layout.list_item_stundenplan, null);
}

TextView fachText = (TextView)v.findViewById(R.id.textViewStundenplanFach);
TextView raumText = (TextView)v.findViewById(R.id.textViewStundenplanRaum);
View colorBlock = (View)v.findViewById(R.id.colorBlockStundenplan);

StundenplanDetail msg = _data.get(position);
fachText.setText(msg.fach);
raumText.setText(msg.raum);
colorBlock.setBackgroundColor(37000000);;

return v;
}

}


Now the problem is, that eclipse tells me that The constructor StundenplanAdapter(ArrayList, Stundenplan.DummySectionFragment) is undefined but i want to use my custom adapter. Every thing works. The List View in my Fragment and the Custom adapter but not if I want to use the custom adapter in my fragment-listview


I hope you can help me thanks in advance, MoBr114



.

stackoverflow.comm

[android help] XML file is created only once not every time when application is executed

android - XML file is created only once not every time when application is executed - Stack Overflow








Tell me more ×

Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

















I'm trying to generate XML file on sdcard. I've added user permission in Manifest file but when I plug my phone though usb and run the application in eclipse then for the first time xml file gets created but when I again run application through phone only or through eclipse then it doesn't gets created. For the file to get created I've to reconnect my phone through usb and in that also it gets created only once. Please help me.


package com.example.samplexml;



import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerException;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult;


import org.w3c.dom.Document;
import org.w3c.dom.Element;


import android.os.Bundle;
import android.os.Environment;
import android.app.Activity;
import android.content.Context;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import android.widget.Toast;

public class MainActivity extends Activity {
TextView myTextView;
EditText E1;
EditText E2;
EditText E3;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);


Button b1= (Button) findViewById(R.id.button1);
Button b3= (Button) findViewById(R.id.button3);
E1 = (EditText) findViewById(R.id.editText1);
E2 = (EditText) findViewById(R.id.editText2);
E3 = (EditText) findViewById(R.id.editText3);

b1.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View arg0) {




DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();
DocumentBuilder docBuilder;
try {
docBuilder = docFactory.newDocumentBuilder();


// root elements
Document doc = docBuilder.newDocument();
Element rootElement = doc.createElement("Class");
doc.appendChild(rootElement);

// staff elements
Element student = doc.createElement("Student");
rootElement.appendChild(student);


// firstname elements
Element firstname = doc.createElement("firstname");
firstname.appendChild(doc.createTextNode(E1.getText().toString()));
student.appendChild(firstname);

Element Email = doc.createElement("Email");
Email.appendChild(doc.createTextNode(E2.getText().toString()));
student.appendChild(Email);

// nickname elements
Element Roll = doc.createElement("Roll_No");
Roll.appendChild(doc.createTextNode(E3.getText().toString()));
student.appendChild(Roll);


// write the content into xml file
TransformerFactory transformerFactory = TransformerFactory.newInstance();



Transformer transformer = transformerFactory.newTransformer();


DOMSource source = new DOMSource(doc);

File FF=new File(Environment.getExternalStorageDirectory()+"//new.xml");
try {
FF.createNewFile();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}

StreamResult result = new StreamResult(FF);




transformer.transform(source, result);

}
catch (ParserConfigurationException e) {

e.printStackTrace();
}
catch (TransformerException e) {

e.printStackTrace();}
Toast.makeText(getApplicationContext(),
Environment.getExternalStorageDirectory().toString(), Toast.LENGTH_LONG).show();


}
});

b3.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
// Close the application
finish(); }});
}
}















Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.










lang-xml







.

stackoverflow.comm

[android help] set mediaPlayer Volume dynamically while playing sound


I am having an application in which I am playing a sound with the help of MediaPlayer in a service,which is running properly. But what I want is to set the volume of the sound with the help of seekBar or something dynamically while the sound is being played. The code is as follow:


PlayerActivity:



public void onClick(View src) {
switch (src.getId()) {
case R.id.buttonStart:
Log.d(TAG, "onClick: starting srvice");

startService(new Intent(this, MyService.class));
break;
case R.id.buttonStop:
Log.d(TAG, "onClick: stopping srvice");

stopService(new Intent(this, MyService.class));
break;
}
}


MyService.java



@Override
public void onCreate() {
player = MediaPlayer.create(this, R.raw.sound);
player.setLooping(false); // Set looping
}

@Override
public void onDestroy() {
player.stop();

}

@Override
public void onStart(Intent intent, int startid) {
player.start();
}


How would I set a seekbar and set the volume of sound while it is playing. Thanks.



.

stackoverflow.comm

[android help] UnExpected reply from GCM Server when i am sendint the Expected URL


**Question (i)**


I have registered my android app in my mobile (Samsung Galaxy Pop) i am recieved a



registrataion_id
APA91bG9NI4U2jr4sUn1HLy5nHMFe1e0JOTgOoZv1Px**********************************


when i sent this registration_id to server side code which is refrenced from here here i used function SendNotification having 2 parameters


  1. My Registration_ID

  2. My Message Which i want to show on notufication

http://www.codeproject.com/Tips/434338/Android-GCM-Push-Notification


I hit the GCM- Server and the result I got is



id=0:1368258967353783%978fee9266d6cf16


I did not understand what does this response means ? is it good ? bad ?


Question (ii)


if mobile device gets registration id from gcm server is it registered or still waiting for server side to send the Registration ID to GCM Server


Please help !! , Thanks in advance



.

stackoverflow.comm

Google Voice on T-Mobile? [General]

Google Voice on T-Mobile? So I recently switched from a GNex on Verizon to a Moto X DE on T-Mobile. I had always used Google Voice for my v...