Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6342)

Unified Diff: chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_model.h

Issue 2617543002: Create Desktop to iOS Promotion skeleton. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_model.h
diff --git a/chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_model.h b/chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_model.h
new file mode 100644
index 0000000000000000000000000000000000000000..5c07f227191284ba6f39356cc0a956a06e6e63c1
--- /dev/null
+++ b/chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_model.h
@@ -0,0 +1,37 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_DESKTOP_IOS_PROMOTION_DESKTOP_IOS_PROMOTION_MODEL_H_
+#define CHROME_BROWSER_UI_DESKTOP_IOS_PROMOTION_DESKTOP_IOS_PROMOTION_MODEL_H_
+
+#include <memory>
sky 2017/01/04 20:52:36 AFAICT you don't use this include.
mrefaat 2017/01/05 00:04:09 Done.
+
+#include "base/macros.h"
+#include "chrome/browser/ui/desktop_ios_promotion/desktop_ios_promotion_util.h"
sky 2017/01/04 20:52:36 Generally we forward declare when possible (it's i
mrefaat 2017/01/05 00:04:09 Done.
+
+// This model provides data to the Desktop to mobile promotion and control the
+// promotion actions.
+class DesktopIOSPromotionModel {
sky 2017/01/04 20:52:37 How come you are naming this class as the model? T
mrefaat 2017/01/05 00:03:08 i thought first i'd name it Controller - but after
vasilii 2017/01/05 17:40:20 For the password manager there are two classes: Ma
mrefaat 2017/01/05 23:54:42 i changed it to be controller instead
+ public:
+ // Should be instantiated on the UI thread.
+ explicit DesktopIOSPromotionModel(
+ desktop_ios_promotion::PromotionEntryPoint entry_point);
+
sky 2017/01/04 20:52:37 Don't inline the destructor.
mrefaat 2017/01/05 00:03:08 Done.
+ // Called by the view code when "Send SMS" button is clicked by the user.
+ void OnSendSMSClicked();
+
+ // Called by the view code when "No Thanks" button is clicked by the user.
+ void OnNoThanksClicked();
+
+ private:
+
sky 2017/01/04 20:52:36 remove newline.
mrefaat 2017/01/05 00:03:08 Done.
+ desktop_ios_promotion::PromotionEntryPoint entry_point_;
sky 2017/01/04 20:52:36 const
mrefaat 2017/01/05 00:03:08 Done.
+
+ // (TODO): If needed verify that functions that affect the UI are done
+ // on the same thread.
+
+ DISALLOW_COPY_AND_ASSIGN(DesktopIOSPromotionModel);
+};
+
+#endif // CHROME_BROWSER_UI_DESKTOP_IOS_PROMOTION_DESKTOP_IOS_PROMOTION_MODEL_H_

Powered by Google App Engine
This is Rietveld 408576698