| 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 #ifndef BASE_MAC_MAC_UTIL_H_ | 5 #ifndef BASE_MAC_MAC_UTIL_H_ |
| 6 #define BASE_MAC_MAC_UTIL_H_ | 6 #define BASE_MAC_MAC_UTIL_H_ |
| 7 | 7 |
| 8 #include <Carbon/Carbon.h> | 8 #include <Carbon/Carbon.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 // |kFullScreenModeAutoHideAll| requests, this will reshow the menu bar. Must | 58 // |kFullScreenModeAutoHideAll| requests, this will reshow the menu bar. Must |
| 59 // be called on main thread. | 59 // be called on main thread. |
| 60 BASE_EXPORT void ReleaseFullScreen(FullScreenMode mode); | 60 BASE_EXPORT void ReleaseFullScreen(FullScreenMode mode); |
| 61 | 61 |
| 62 // Convenience method to switch the current fullscreen mode. This has the same | 62 // Convenience method to switch the current fullscreen mode. This has the same |
| 63 // net effect as a ReleaseFullScreen(from_mode) call followed immediately by a | 63 // net effect as a ReleaseFullScreen(from_mode) call followed immediately by a |
| 64 // RequestFullScreen(to_mode). Must be called on the main thread. | 64 // RequestFullScreen(to_mode). Must be called on the main thread. |
| 65 BASE_EXPORT void SwitchFullScreenModes(FullScreenMode from_mode, | 65 BASE_EXPORT void SwitchFullScreenModes(FullScreenMode from_mode, |
| 66 FullScreenMode to_mode); | 66 FullScreenMode to_mode); |
| 67 | 67 |
| 68 // Returns true if this process is in the foreground, meaning that it's the | |
| 69 // frontmost process, the one whose menu bar is shown at the top of the main | |
| 70 // display. | |
| 71 BASE_EXPORT bool AmIForeground(); | |
| 72 | |
| 73 // Excludes the file given by |file_path| from being backed up by Time Machine. | 68 // Excludes the file given by |file_path| from being backed up by Time Machine. |
| 74 BASE_EXPORT bool SetFileBackupExclusion(const FilePath& file_path); | 69 BASE_EXPORT bool SetFileBackupExclusion(const FilePath& file_path); |
| 75 | 70 |
| 76 // Checks if the current application is set as a Login Item, so it will launch | 71 // Checks if the current application is set as a Login Item, so it will launch |
| 77 // on Login. If a non-NULL pointer to is_hidden is passed, the Login Item also | 72 // on Login. If a non-NULL pointer to is_hidden is passed, the Login Item also |
| 78 // is queried for the 'hide on launch' flag. | 73 // is queried for the 'hide on launch' flag. |
| 79 BASE_EXPORT bool CheckLoginItemStatus(bool* is_hidden); | 74 BASE_EXPORT bool CheckLoginItemStatus(bool* is_hidden); |
| 80 | 75 |
| 81 // Adds current application to the set of Login Items with specified "hide" | 76 // Adds current application to the set of Login Items with specified "hide" |
| 82 // flag. This has the same effect as adding/removing the application in | 77 // flag. This has the same effect as adding/removing the application in |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 // If any error occurs, none of the input pointers are touched. | 169 // If any error occurs, none of the input pointers are touched. |
| 175 BASE_EXPORT bool ParseModelIdentifier(const std::string& ident, | 170 BASE_EXPORT bool ParseModelIdentifier(const std::string& ident, |
| 176 std::string* type, | 171 std::string* type, |
| 177 int32_t* major, | 172 int32_t* major, |
| 178 int32_t* minor); | 173 int32_t* minor); |
| 179 | 174 |
| 180 } // namespace mac | 175 } // namespace mac |
| 181 } // namespace base | 176 } // namespace base |
| 182 | 177 |
| 183 #endif // BASE_MAC_MAC_UTIL_H_ | 178 #endif // BASE_MAC_MAC_UTIL_H_ |
| OLD | NEW |