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 "chrome/browser/sessions/session_backend.h" | 5 #include "chrome/browser/sessions/session_backend.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "base/file_util.h" | |
10 #include "base/files/file.h" | 9 #include "base/files/file.h" |
| 10 #include "base/files/file_util.h" |
11 #include "base/memory/scoped_vector.h" | 11 #include "base/memory/scoped_vector.h" |
12 #include "base/metrics/histogram.h" | 12 #include "base/metrics/histogram.h" |
13 #include "base/threading/thread_restrictions.h" | 13 #include "base/threading/thread_restrictions.h" |
14 | 14 |
15 using base::TimeTicks; | 15 using base::TimeTicks; |
16 | 16 |
17 // File version number. | 17 // File version number. |
18 static const int32 kFileCurrentVersion = 1; | 18 static const int32 kFileCurrentVersion = 1; |
19 | 19 |
20 // The signature at the beginning of the file = SSNS (Sessions). | 20 // The signature at the beginning of the file = SSNS (Sessions). |
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
395 } | 395 } |
396 | 396 |
397 base::FilePath SessionBackend::GetCurrentSessionPath() { | 397 base::FilePath SessionBackend::GetCurrentSessionPath() { |
398 base::FilePath path = path_to_dir_; | 398 base::FilePath path = path_to_dir_; |
399 if (type_ == BaseSessionService::TAB_RESTORE) | 399 if (type_ == BaseSessionService::TAB_RESTORE) |
400 path = path.AppendASCII(kCurrentTabSessionFileName); | 400 path = path.AppendASCII(kCurrentTabSessionFileName); |
401 else | 401 else |
402 path = path.AppendASCII(kCurrentSessionFileName); | 402 path = path.AppendASCII(kCurrentSessionFileName); |
403 return path; | 403 return path; |
404 } | 404 } |
OLD | NEW |