projects
/
pub
/
Android
/
ownCloud.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'develop' into setup_buttons
[pub/Android/ownCloud.git]
/
src
/
com
/
owncloud
/
android
/
DisplayUtils.java
diff --git
a/src/com/owncloud/android/DisplayUtils.java
b/src/com/owncloud/android/DisplayUtils.java
index
f436852
..
1ee898b
100644
(file)
--- a/
src/com/owncloud/android/DisplayUtils.java
+++ b/
src/com/owncloud/android/DisplayUtils.java
@@
-1,11
+1,10
@@
/* ownCloud Android client application
\r
* Copyright (C) 2011 Bartek Przybylski
\r
/* ownCloud Android client application
\r
* Copyright (C) 2011 Bartek Przybylski
\r
- * Copyright (
2
) 2012-2013 ownCloud Inc.
\r
+ * Copyright (
C
) 2012-2013 ownCloud Inc.
\r
*
\r
* This program is free software: you can redistribute it and/or modify
\r
*
\r
* This program is free software: you can redistribute it and/or modify
\r
- * it under the terms of the GNU General Public License as published by
\r
- * the Free Software Foundation, either version 3 of the License, or
\r
- * (at your option) any later version.
\r
+ * it under the terms of the GNU General Public License version 2,
\r
+ * as published by the Free Software Foundation.
\r
*
\r
* This program is distributed in the hope that it will be useful,
\r
* but WITHOUT ANY WARRANTY; without even the implied warranty of
\r
*
\r
* This program is distributed in the hope that it will be useful,
\r
* but WITHOUT ANY WARRANTY; without even the implied warranty of
\r
@@
-25,8
+24,6
@@
import java.util.HashMap;
import java.util.HashSet;
\r
import java.util.Set;
\r
\r
import java.util.HashSet;
\r
import java.util.Set;
\r
\r
-import android.util.Log;
\r
-
\r
/**
\r
* A helper class for some string operations.
\r
*
\r
/**
\r
* A helper class for some string operations.
\r
*
\r
@@
-35,7
+32,7
@@
import android.util.Log;
*/
\r
public class DisplayUtils {
\r
\r
*/
\r
public class DisplayUtils {
\r
\r
- private static String TAG = DisplayUtils.class.getSimpleName();
\r
+
//
private static String TAG = DisplayUtils.class.getSimpleName();
\r
\r
private static final String[] sizeSuffixes = { "B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB" };
\r
\r
\r
private static final String[] sizeSuffixes = { "B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB" };
\r
\r
@@
-145,7
+142,7
@@
public class DisplayUtils {
} else {
\r
String [] parts = mimetype.split("/");
\r
String type = parts[0];
\r
} else {
\r
String [] parts = mimetype.split("/");
\r
String type = parts[0];
\r
- String subtype =
parts[1]
;
\r
+ String subtype =
(parts.length > 1) ? parts[1] : ""
;
\r
\r
if(TYPE_TXT.equals(type)) {
\r
return R.drawable.file_doc;
\r
\r
if(TYPE_TXT.equals(type)) {
\r
return R.drawable.file_doc;
\r