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 CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
363 void SetIcon(const SkBitmap* icon); | 363 void SetIcon(const SkBitmap* icon); |
364 | 364 |
365 // ImageLoader callback. | 365 // ImageLoader callback. |
366 void OnImageLoaded(const gfx::Image& image); | 366 void OnImageLoaded(const gfx::Image& image); |
367 | 367 |
368 // Starts the process of showing a confirmation UI, which is split into two. | 368 // Starts the process of showing a confirmation UI, which is split into two. |
369 // 1) Set off a 'load icon' task. | 369 // 1) Set off a 'load icon' task. |
370 // 2) Handle the load icon response and show the UI (OnImageLoaded). | 370 // 2) Handle the load icon response and show the UI (OnImageLoaded). |
371 void LoadImageIfNeeded(); | 371 void LoadImageIfNeeded(); |
372 | 372 |
373 // Starts fetching warnings for OAuth2 scopes, if there are any. | |
374 void FetchOAuthIssueAdviceIfNeeded(); | |
375 | |
376 // OAuth2TokenService::Consumer implementation: | 373 // OAuth2TokenService::Consumer implementation: |
377 virtual void OnGetTokenSuccess(const OAuth2TokenService::Request* request, | 374 virtual void OnGetTokenSuccess(const OAuth2TokenService::Request* request, |
378 const std::string& access_token, | 375 const std::string& access_token, |
379 const base::Time& expiration_time) OVERRIDE; | 376 const base::Time& expiration_time) OVERRIDE; |
380 virtual void OnGetTokenFailure(const OAuth2TokenService::Request* request, | 377 virtual void OnGetTokenFailure(const OAuth2TokenService::Request* request, |
381 const GoogleServiceAuthError& error) OVERRIDE; | 378 const GoogleServiceAuthError& error) OVERRIDE; |
382 | 379 |
383 // OAuth2MintTokenFlow::Delegate implementation: | 380 // OAuth2MintTokenFlow::Delegate implementation: |
384 virtual void OnIssueAdviceSuccess( | 381 virtual void OnIssueAdviceSuccess( |
385 const IssueAdviceInfo& issue_advice) OVERRIDE; | 382 const IssueAdviceInfo& issue_advice) OVERRIDE; |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 Prompt prompt_; | 414 Prompt prompt_; |
418 | 415 |
419 scoped_ptr<OAuth2TokenService::Request> login_token_request_; | 416 scoped_ptr<OAuth2TokenService::Request> login_token_request_; |
420 scoped_ptr<OAuth2MintTokenFlow> token_flow_; | 417 scoped_ptr<OAuth2MintTokenFlow> token_flow_; |
421 | 418 |
422 // Used to show the confirm dialog. | 419 // Used to show the confirm dialog. |
423 ShowDialogCallback show_dialog_callback_; | 420 ShowDialogCallback show_dialog_callback_; |
424 }; | 421 }; |
425 | 422 |
426 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ | 423 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_PROMPT_H_ |
OLD | NEW |