| OLD | NEW |
| 1 // Copyright (c) 2009-2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2009-2010 The Chromium OS 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 "login_manager/session_manager_service.h" | 5 #include "login_manager/session_manager_service.h" |
| 6 | 6 |
| 7 #include <dbus/dbus-glib-lowlevel.h> | 7 #include <dbus/dbus-glib-lowlevel.h> |
| 8 #include <errno.h> | 8 #include <errno.h> |
| 9 #include <glib.h> | 9 #include <glib.h> |
| 10 #include <grp.h> | 10 #include <grp.h> |
| (...skipping 710 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 721 std::string decoded; | 721 std::string decoded; |
| 722 if (!GetPropertyHelper(name, &value, &decoded, error)) | 722 if (!GetPropertyHelper(name, &value, &decoded, error)) |
| 723 return FALSE; | 723 return FALSE; |
| 724 | 724 |
| 725 *OUT_value = g_strdup_printf("%.*s", value.length(), value.c_str()); | 725 *OUT_value = g_strdup_printf("%.*s", value.length(), value.c_str()); |
| 726 *OUT_signature = g_array_sized_new(FALSE, FALSE, 1, decoded.length()); | 726 *OUT_signature = g_array_sized_new(FALSE, FALSE, 1, decoded.length()); |
| 727 g_array_append_vals(*OUT_signature, decoded.c_str(), decoded.length()); | 727 g_array_append_vals(*OUT_signature, decoded.c_str(), decoded.length()); |
| 728 return TRUE; | 728 return TRUE; |
| 729 } | 729 } |
| 730 | 730 |
| 731 gboolean SessionManagerService::StorePolicy(gchar* policy_blob, |
| 732 GArray* signature, |
| 733 GError** error) { |
| 734 return FALSE; |
| 735 } |
| 736 |
| 737 gboolean SessionManagerService::RetrievePolicy(gchar** OUT_policy_blob, |
| 738 GArray** OUT_signature, |
| 739 GError** error) { |
| 740 return FALSE; |
| 741 } |
| 742 |
| 731 gboolean SessionManagerService::LockScreen(GError** error) { | 743 gboolean SessionManagerService::LockScreen(GError** error) { |
| 732 screen_locked_ = TRUE; | 744 screen_locked_ = TRUE; |
| 733 system_->SendSignalToChromium(chromium::kLockScreenSignal, NULL); | 745 system_->SendSignalToChromium(chromium::kLockScreenSignal, NULL); |
| 734 LOG(INFO) << "LockScreen"; | 746 LOG(INFO) << "LockScreen"; |
| 735 return TRUE; | 747 return TRUE; |
| 736 } | 748 } |
| 737 | 749 |
| 738 gboolean SessionManagerService::UnlockScreen(GError** error) { | 750 gboolean SessionManagerService::UnlockScreen(GError** error) { |
| 739 screen_locked_ = FALSE; | 751 screen_locked_ = FALSE; |
| 740 system_->SendSignalToChromium(chromium::kUnlockScreenSignal, NULL); | 752 system_->SendSignalToChromium(chromium::kUnlockScreenSignal, NULL); |
| (...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1219 arg_list.push_back(args[i_arg]); | 1231 arg_list.push_back(args[i_arg]); |
| 1220 } | 1232 } |
| 1221 } | 1233 } |
| 1222 if (arg_list.size()) { | 1234 if (arg_list.size()) { |
| 1223 arg_lists.push_back(arg_list); | 1235 arg_lists.push_back(arg_list); |
| 1224 } | 1236 } |
| 1225 return arg_lists; | 1237 return arg_lists; |
| 1226 } | 1238 } |
| 1227 | 1239 |
| 1228 } // namespace login_manager | 1240 } // namespace login_manager |
| OLD | NEW |