| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "storage/browser/blob/view_blob_internals_job.h" | 5 #include "storage/browser/blob/view_blob_internals_job.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/format_macros.h" | 9 #include "base/format_macros.h" |
| 10 #include "base/i18n/number_formatting.h" | 10 #include "base/i18n/number_formatting.h" |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 216 if (!item.expected_modification_time().is_null()) { | 216 if (!item.expected_modification_time().is_null()) { |
| 217 AddHTMLListItem(kModificationTime, base::UTF16ToUTF8( | 217 AddHTMLListItem(kModificationTime, base::UTF16ToUTF8( |
| 218 TimeFormatFriendlyDateAndTime(item.expected_modification_time())), | 218 TimeFormatFriendlyDateAndTime(item.expected_modification_time())), |
| 219 out); | 219 out); |
| 220 } | 220 } |
| 221 break; | 221 break; |
| 222 case DataElement::TYPE_DISK_CACHE_ENTRY: | 222 case DataElement::TYPE_DISK_CACHE_ENTRY: |
| 223 AddHTMLListItem(kType, "disk cache entry", out); | 223 AddHTMLListItem(kType, "disk cache entry", out); |
| 224 AddHTMLListItem(kURL, item.disk_cache_entry()->GetKey(), out); | 224 AddHTMLListItem(kURL, item.disk_cache_entry()->GetKey(), out); |
| 225 break; | 225 break; |
| 226 case DataElement::TYPE_BYTES_DESCRIPTION: |
| 226 case DataElement::TYPE_UNKNOWN: | 227 case DataElement::TYPE_UNKNOWN: |
| 227 NOTREACHED(); | 228 NOTREACHED(); |
| 228 break; | 229 break; |
| 229 } | 230 } |
| 230 if (item.offset()) { | 231 if (item.offset()) { |
| 231 AddHTMLListItem(kOffset, base::UTF16ToUTF8(base::FormatNumber( | 232 AddHTMLListItem(kOffset, base::UTF16ToUTF8(base::FormatNumber( |
| 232 static_cast<int64>(item.offset()))), out); | 233 static_cast<int64>(item.offset()))), out); |
| 233 } | 234 } |
| 234 if (static_cast<int64>(item.length()) != -1) { | 235 if (static_cast<int64>(item.length()) != -1) { |
| 235 AddHTMLListItem(kLength, base::UTF16ToUTF8(base::FormatNumber( | 236 AddHTMLListItem(kLength, base::UTF16ToUTF8(base::FormatNumber( |
| 236 static_cast<int64>(item.length()))), out); | 237 static_cast<int64>(item.length()))), out); |
| 237 } | 238 } |
| 238 | 239 |
| 239 if (has_multi_items) | 240 if (has_multi_items) |
| 240 EndHTMLList(out); | 241 EndHTMLList(out); |
| 241 } | 242 } |
| 242 | 243 |
| 243 EndHTMLList(out); | 244 EndHTMLList(out); |
| 244 } | 245 } |
| 245 | 246 |
| 246 } // namespace storage | 247 } // namespace storage |
| OLD | NEW |