[ClockApps] - Countdown Timer and Stopwatch

Search for BETA-testers and/or promote your own Application in a decent way.

Postby JD82 » Sun Feb 21, 2010 12:59 pm

giridhari wrote:Can you show me the code for stop clock ?

+1

It would be useful to me also :)
User avatar
JD82
Freshman
Freshman
 
Posts: 9
Joined: Fri Feb 19, 2010 8:18 pm
Location: Italy

Top

Postby dafi81 » Fri Apr 02, 2010 7:22 am

dafi81
Once Poster
Once Poster
 
Posts: 1
Joined: Fri Apr 02, 2010 7:18 am

Hey

Postby dr03baby » Sat Apr 17, 2010 1:56 am

In your Stop Watch number 2, I would like to see your source code or matter of fact how did made it so it would record each lap...

Thanks Sauly
dr03baby
Once Poster
Once Poster
 
Posts: 1
Joined: Sat Apr 17, 2010 1:36 am
Location: Paterson,Nj

Postby skate15e » Fri Apr 23, 2010 3:46 am

Thanks for all the insight, you helped me fix a stopwatch problem in my program. I was wondering, how did you display milliseconds for the stopwatch? Thanks in advance for the help.
skate15e
Once Poster
Once Poster
 
Posts: 1
Joined: Fri Apr 23, 2010 3:40 am

Postby Yellowdog » Sun May 02, 2010 7:30 pm

I am really interested in finding code for getting access to the ringtones and playing the ring. If you could share that would be great!

I have found some code that gets the ringtones ect, just not too fimilar with uri's. Any insight would be great!
package com.mine;
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1.  
  2. import android.app.Activity;
  3.  
  4. import android.content.ContentUris;
  5.  
  6. import android.content.Intent;
  7.  
  8. import android.media.RingtoneManager;
  9.  
  10. import android.net.Uri;
  11.  
  12. import android.os.Bundle;
  13.  
  14. import android.provider.MediaStore;
  15.  
  16. import android.util.Log;
  17.  
  18. import android.view.View;
  19.  
  20. import android.view.View.OnClickListener;
  21.  
  22. import android.widget.TextView;
  23.  
  24.  
  25.  
  26. public class Sample extends Activity implements OnClickListener {
  27.  
  28.         /** Called when the activity is first created. */
  29.  
  30.         private TextView textView;
  31.  
  32.  
  33.  
  34.         @Override
  35.  
  36.         public void onCreate(Bundle savedInstanceState) {
  37.  
  38.                 super.onCreate(savedInstanceState);
  39.  
  40.                 setContentView(R.layout.main);
  41.  
  42.                 textView = (TextView) findViewById(R.id.sample);
  43.  
  44.                 textView.setOnClickListener(this);
  45.  
  46.         }
  47.  
  48.  
  49.  
  50.         @Override
  51.  
  52.         public void onClick(View v) {
  53.  
  54.                 Intent intent = new Intent(RingtoneManager.ACTION_RINGTONE_PICKER);
  55.  
  56.                 intent.putExtra(RingtoneManager.EXTRA_RINGTONE_TITLE,
  57.  
  58.                                 "My customised Title");
  59.  
  60.                 Uri uri = ContentUris.withAppendedId(
  61.  
  62.                                 MediaStore.Audio.Media.EXTERNAL_CONTENT_URI, 1l);
  63.  
  64.                 // Don't show 'Silent'
  65.  
  66.                 intent.putExtra(RingtoneManager.EXTRA_RINGTONE_SHOW_SILENT, false);
  67.  
  68.  
  69.  
  70.                 intent.putExtra(RingtoneManager.EXTRA_RINGTONE_EXISTING_URI, uri);
  71.  
  72.                 startActivityForResult(intent, 123);
  73.  
  74.  
  75.  
  76.         }
  77.  
  78.  
  79.  
  80.         @Override
  81.  
  82.         protected void onActivityResult(int requestCode, int resultCode, Intent data) {
  83.  
  84.                 switch (resultCode) {
  85.  
  86.                 /*
  87.  
  88.                  * case RESULT_OK: this.setResult(RESULT_OK); this.finish(); break;
  89.  
  90.                  */
  91.  
  92.  
  93.  
  94.                 case RESULT_OK:
  95.  
  96.                         Uri uri = data
  97.  
  98.                                         .getParcelableExtra(RingtoneManager.EXTRA_RINGTONE_PICKED_URI);
  99.  
  100.                         Log.i("Sample", "uri " + uri);
  101.  
  102.                         RingtoneManager.setActualDefaultRingtoneUri(this,
  103.  
  104.                                         RingtoneManager.TYPE_RINGTONE, uri);
  105.  
  106.                         break;
  107.  
  108.                 }
  109.  
  110.         }
  111.  
  112. }
Parsed in 0.037 seconds, using GeSHi 1.0.8.4


Just dont know how I can save the selected ring and play it on an event. Thanks again if you can help.
Yellowdog
Junior Developer
Junior Developer
 
Posts: 20
Joined: Thu Apr 22, 2010 6:37 am

Re: [ClockApps] - Countdown Timer and Stopwatch

Postby fennymanohar » Sat Dec 18, 2010 3:54 am

haiii
I'm currently working on Android..
saw the widgets about CountDown Timers in this site..
they r too good
i want code for CountDown Timers..
Please some one post the code
fennymanohar
Once Poster
Once Poster
 
Posts: 1
Joined: Sat Dec 18, 2010 3:49 am

Top
Previous

Return to Promote your Android Application

Who is online

Users browsing this forum: No registered users and 3 guests