| OLD | NEW | 
|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 
| 6 #define CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 6 #define CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 
| 7 #pragma once | 7 #pragma once | 
| 8 | 8 | 
| 9 #include <string> | 9 #include <string> | 
| 10 #include <vector> | 10 #include <vector> | 
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 151   // Reloading can be disabled e. g. for the DevTools window. | 151   // Reloading can be disabled e. g. for the DevTools window. | 
| 152   virtual bool CanReloadContents(TabContents* source) const; | 152   virtual bool CanReloadContents(TabContents* source) const; | 
| 153 | 153 | 
| 154   // Show a dialog with HTML content. |delegate| contains a pointer to the | 154   // Show a dialog with HTML content. |delegate| contains a pointer to the | 
| 155   // delegate who knows how to display the dialog (which file URL and JSON | 155   // delegate who knows how to display the dialog (which file URL and JSON | 
| 156   // string input to use during initialization). |parent_window| is the window | 156   // string input to use during initialization). |parent_window| is the window | 
| 157   // that should be parent of the dialog, or NULL for the default. | 157   // that should be parent of the dialog, or NULL for the default. | 
| 158   virtual void ShowHtmlDialog(HtmlDialogUIDelegate* delegate, | 158   virtual void ShowHtmlDialog(HtmlDialogUIDelegate* delegate, | 
| 159                               gfx::NativeWindow parent_window); | 159                               gfx::NativeWindow parent_window); | 
| 160 | 160 | 
|  | 161   // Invoked prior to showing before unload handler confirmation dialog. | 
|  | 162   virtual void WillRunBeforeUnloadConfirm(); | 
|  | 163 | 
| 161   // Returns true if javascript dialogs and unload alerts are suppressed. | 164   // Returns true if javascript dialogs and unload alerts are suppressed. | 
| 162   // Default is false. | 165   // Default is false. | 
| 163   virtual bool ShouldSuppressDialogs(); | 166   virtual bool ShouldSuppressDialogs(); | 
| 164 | 167 | 
| 165   // Tells us that we've finished firing this tab's beforeunload event. | 168   // Tells us that we've finished firing this tab's beforeunload event. | 
| 166   // The proceed bool tells us whether the user chose to proceed closing the | 169   // The proceed bool tells us whether the user chose to proceed closing the | 
| 167   // tab. Returns true if the tab can continue on firing it's unload event. | 170   // tab. Returns true if the tab can continue on firing it's unload event. | 
| 168   // If we're closing the entire browser, then we'll want to delay firing | 171   // If we're closing the entire browser, then we'll want to delay firing | 
| 169   // unload events until all the beforeunload events have fired. | 172   // unload events until all the beforeunload events have fired. | 
| 170   virtual void BeforeUnloadFired(TabContents* tab, | 173   virtual void BeforeUnloadFired(TabContents* tab, | 
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 316 | 319 | 
| 317   // Notifies the delegate that the content restrictions for this tab has | 320   // Notifies the delegate that the content restrictions for this tab has | 
| 318   // changed. | 321   // changed. | 
| 319   virtual void ContentRestrictionsChanged(TabContents* source); | 322   virtual void ContentRestrictionsChanged(TabContents* source); | 
| 320 | 323 | 
| 321  protected: | 324  protected: | 
| 322   virtual ~TabContentsDelegate(); | 325   virtual ~TabContentsDelegate(); | 
| 323 }; | 326 }; | 
| 324 | 327 | 
| 325 #endif  // CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 328 #endif  // CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 
| OLD | NEW | 
|---|