summaryrefslogtreecommitdiffstats
path: root/chrome/browser/app_modal_dialog.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix probably a lot of crash bugs. There was a member variable in ↵ben@chromium.org2010-10-021-1/+1
| | | | | | | | | | | JSModalDialog that was masking the one in AppModalDialog that really mattered. This was preventing proper cleanup of the alert window under certain circumstances. http://crbug.com/57368 TEST=none Review URL: http://codereview.chromium.org/3543008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@61315 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor AppModalDialog to more clearly isolate platform specific UI pieces ↵ben@chromium.org2010-09-281-62/+33
| | | | | | | | | | | and eliminate the dependency on individual frontends from cross platform code. BUG=none TEST=none Review URL: http://codereview.chromium.org/3398015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60785 0039d316-1c4b-4281-b951-d872f2087c98
* Delete obviously unneeded forward declarations in chrome/browser/*.h.viettrungluu@chromium.org2010-08-051-4/+1
| | | | | | | | | BUG=none TEST=builds Review URL: http://codereview.chromium.org/3080031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55037 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* [Mac] augment modal cookie prompt on mac to include details panedanno@chromium.org2010-03-121-7/+4
| | | | | | | | | | | | | | | | Added two new xibs. The first is a cookie info view that is shared between the tree that shows browser data and the cookie modal prompt to block accepting cookies. The second is a window to replace the NSAlert modal dialog for the cookie prompt. Modified cookie tree code and added cookie prompt code to use new xibs. Changed "hidden" handling of cookie detail view to use bindings rather than explicit code. TODOs for http://crbug.com/36948 not in this CL: - changing the expiration for cookies isn't implemented TEST=manually testing of modal cookie prompt, new unit tests BUG=http://crbug.com/36948 Review URL: http://codereview.chromium.org/669127 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41408 0039d316-1c4b-4281-b951-d872f2087c98
* BSD ifdefs, etc. necessary for chrome/pvalchev@google.com2010-03-091-2/+2
| | | | | | Review URL: http://codereview.chromium.org/656009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41067 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes two bugs in cookie prompting:sky@chromium.org2010-02-181-0/+10
| | | | | | | | | | | | | | | | | | . In certain situations we could crash because we weren't letting CookiePromptView::Init complete and then attempting to reference some NULL fields. I've fixed this by adding AppModalDialog::IsValid and moving the logic that was in Init to IsValid. This way we only create CookiePromptView when needed. . We were leaking AppModalDialogs. I've made CookiePromptView own the AppModalDialog and delete it when the CookiePromptView is deleted. BUG=36079 TEST=enable prompting for cookies, go to a bunch of sites make sure you don't crash. Review URL: http://codereview.chromium.org/632006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39328 0039d316-1c4b-4281-b951-d872f2087c98
* Refactored out JS specific part of modal dialog stack into its own class, ↵zelidrag@chromium.org2010-02-051-69/+36
| | | | | | | | | | | exposed cookie/storage prompt as a modal dialog. BUG=32719 TEST=none, requires Darin to hook this with his code. Review URL: http://codereview.chromium.org/560030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38268 0039d316-1c4b-4281-b951-d872f2087c98
* BSD port: chrome/app and chrome/browser ifdef cleaningpvalchev@google.com2010-02-011-3/+3
| | | | | | Review URL: http://codereview.chromium.org/548203 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37714 0039d316-1c4b-4281-b951-d872f2087c98
* Fix js alert crasher when window is closed by jsfeldstein@chromium.org2010-01-221-1/+6
| | | | | | | | | | | There was a problem with pages that call window.close() then immediately open a js alert. The problem was that the TabContents would get destroyed, but the alert would stick around, and when you closed the alert, it would try to call back to the tab contents' js, crashing chrome. The other OSs got around this by closing the alert immediately, but mac didn't implement the CloseModalDialog method. This CL implements that. BUG=29580 TEST=Run the html attached to the bug Review URL: http://codereview.chromium.org/549126 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36908 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crash when an extension popup shows a JS alert. Showing the alert takes...rafaelw@chromium.org2009-11-241-2/+11
| | | | | | | | | | | | | | | | Landing this on for pam. Original issue: http://codereview.chromium.org/425011/show. Disable showing JS alerts from popups, because doing so makes the popup disappear immediately, which has all sorts of unfortunate side effects for the poor orphaned alert (see bug for details). BUG=27758 TEST=create extension with popup, put link with |onclick="alert('test');"| in it; install extension, open popup, and click link; see no crash (nor popup) Review URL: http://codereview.chromium.org/435010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32889 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes almost all of the rest of lint errors in the chrome/ directory (minus ↵erg@google.com2009-11-131-1/+1
| | | | | | | | the really hard ones which will need actual review instead of rubber-stamping.) Review URL: http://codereview.chromium.org/386026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31932 0039d316-1c4b-4281-b951-d872f2087c98
* Implement window.alert() and its cousins for extensions.pam@chromium.org2009-11-061-4/+12
| | | | | | | | | | | | Second try, now with fixed observer. BUG=12126 TEST=put a window.prompt() in a background page, a browser action, and a page action. Make sure it gets the result back correctly. Also make sure it still works when called from a web page. Review URL: http://codereview.chromium.org/373006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31204 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 31110 - Implement window.alert() and its cousins for extensions.ben@chromium.org2009-11-051-12/+5
| | | | | | | | | | | | | BUG=12126 TEST=put a window.prompt() in a background page, a browser action, and a page action. Make sure it gets the result back correctly. Also make sure it still works when called from a web page. Review URL: http://codereview.chromium.org/341089 TBR=pam@chromium.org Review URL: http://codereview.chromium.org/360063 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31126 0039d316-1c4b-4281-b951-d872f2087c98
* Implement window.alert() and its cousins for extensions.pam@chromium.org2009-11-051-5/+12
| | | | | | | | | | BUG=12126 TEST=put a window.prompt() in a background page, a browser action, and a page action. Make sure it gets the result back correctly. Also make sure it still works when called from a web page. Review URL: http://codereview.chromium.org/341089 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31110 0039d316-1c4b-4281-b951-d872f2087c98
* Convert JavascriptAlertActivatesTab to browser_tests framework.phajdan.jr@chromium.org2009-07-101-0/+3
| | | | | | | | | | | | This should make it non-flaky, so I un-disabled the test. I also added necessary plumbing so we can wait for AppModalDialog to appear and close it. TEST=Covered by browser_tests. http://crbug.com/16062 Review URL: http://codereview.chromium.org/149460 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20400 0039d316-1c4b-4281-b951-d872f2087c98
* Displaying consecutive alerts from plugins should not hang the browser. The ↵ananta@chromium.org2009-05-151-0/+1
| | | | | | | | | | | | | | | | | | plugins display alerts via the NPN_Evaluate API. The browser signals an event handle to ensure that the plugin starts peeking for messages while waiting for the NPN_Evaluate call to return. When the dialog is dismissed by the user, windows does send some messages to the plugin window underneath, like activation messages, etc. These don't get dispatched as the event is reset when the dialog is dismissed, i.e. much before the window is actually destroyed. The fix is to reset the event handle after the window is actually destroyed. To achieve this I added an OnClose virtual function to the DialogDelegate interface, which is overridden by the JavascriptMessageBoxDialog class which eventually ensures that the event is reset. This fixes http://code.google.com/p/chromium/issues/detail?id=10799 I updated the AlertInWindowMessage npapi test to display two alerts instead of one. Bug=10799 Review URL: http://codereview.chromium.org/113464 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16172 0039d316-1c4b-4281-b951-d872f2087c98
* Replace all occurrances of WebContents with TabContents.brettw@chromium.org2009-05-041-5/+5
| | | | | | Review URL: http://codereview.chromium.org/99177 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15194 0039d316-1c4b-4281-b951-d872f2087c98
* Add a comment explaining the ownership model between AppModalDialogtc@google.com2009-04-171-1/+4
| | | | | | | | | and the NativeDialog. Review URL: http://codereview.chromium.org/77034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13942 0039d316-1c4b-4281-b951-d872f2087c98
* Actually implement js message boxes on linux. This handlestc@google.com2009-04-091-1/+2
| | | | | | | | | | | | | | | alert, confirm and onbeforeunload. prompt has a dialog, but there's no text field. I'll work on that next. It turns out there's no nested message loop on the windows side, so there's no nested message loop here either. BUG=9493 Review URL: http://codereview.chromium.org/63134 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13437 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor AppModalDialogQueue and move JS Alert boxes into a MVC.tc@google.com2009-04-071-0/+109
JavascriptMessageBoxHandler (handles alert, confirm, prompt, and onbeforeunload) was a views class. This change converts it into an MVC so we can port to linux/mac. AppModalDialog is the model+controller, JavascriptMessageBoxDialog is the windows specific view. The onbeforeunload dialog (JavascriptBeforeUnloadHandler) was a subclass of JavascriptMessageBoxHandler that had a different title and button text. I merged this class into JavascriptMessageBoxHandler by passing a bool to handle the custom button text. Review URL: http://codereview.chromium.org/63033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13276 0039d316-1c4b-4281-b951-d872f2087c98