diff options
author | Chiao Cheng <chiaocheng@google.com> | 2012-10-31 15:31:33 -0700 |
---|---|---|
committer | Chiao Cheng <chiaocheng@google.com> | 2012-10-31 16:28:58 -0700 |
commit | c8dd78c595cfaf9766e59a2df012b16d6c05b213 (patch) | |
tree | 852dadb5a2809d2528938f39cd818e66ea1a8d92 /src/com/android/contacts/ContactStatusUtil.java | |
parent | 6dd81dc237a3fb33567fe6f00c406705fcec144b (diff) | |
download | Contacts-c8dd78c595cfaf9766e59a2df012b16d6c05b213.tar.gz |
Moving dependencies of PhoneFavoriteFragment.
Move common classes from Contacts to Contacts Common.
Bug: 6993891
Change-Id: Icff2a57875c47a5141842ca3ab980cfc76931cb6
Diffstat (limited to 'src/com/android/contacts/ContactStatusUtil.java')
-rw-r--r-- | src/com/android/contacts/ContactStatusUtil.java | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/src/com/android/contacts/ContactStatusUtil.java b/src/com/android/contacts/ContactStatusUtil.java deleted file mode 100644 index 4aa24b045..000000000 --- a/src/com/android/contacts/ContactStatusUtil.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (C) 2011 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.android.contacts; - -import android.content.Context; -import android.content.res.Resources; -import android.provider.ContactsContract.StatusUpdates; - -/** - * Provides static function to get default contact status message. - */ -public class ContactStatusUtil { - - private static final String TAG = "ContactStatusUtil"; - - public static String getStatusString(Context context, int presence) { - Resources resources = context.getResources(); - switch (presence) { - case StatusUpdates.AVAILABLE: - return resources.getString(R.string.status_available); - case StatusUpdates.IDLE: - case StatusUpdates.AWAY: - return resources.getString(R.string.status_away); - case StatusUpdates.DO_NOT_DISTURB: - return resources.getString(R.string.status_busy); - case StatusUpdates.OFFLINE: - case StatusUpdates.INVISIBLE: - default: - return null; - } - } - -} |