]> git.saurik.com Git - wxWidgets.git/commitdiff
wxWebKikStateChangedEvent should now return proper values for GetURL(). Also updated...
authorKevin Ollivier <kevino@theolliviers.com>
Wed, 26 May 2004 04:11:43 +0000 (04:11 +0000)
committerKevin Ollivier <kevino@theolliviers.com>
Wed, 26 May 2004 04:11:43 +0000 (04:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27449 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

samples/html/htmlctrl/htmlctrl.cpp
src/html/htmlctrl/webkit/webkit.mm

index 83687c029f3b1ee40c95cd3fc0eb83d0ffeb5425..055a9777950e79a64612f255b0cb39019329d1f6 100755 (executable)
@@ -219,6 +219,7 @@ void MyFrame::OnStateChanged(wxWebKitStateChangedEvent& myEvent){
     if (GetStatusBar() != NULL){
         if (myEvent.GetState() == wxWEBKIT_STATE_NEGOTIATING){
             GetStatusBar()->SetStatusText(_("Contacting ") + myEvent.GetURL());
     if (GetStatusBar() != NULL){
         if (myEvent.GetState() == wxWEBKIT_STATE_NEGOTIATING){
             GetStatusBar()->SetStatusText(_("Contacting ") + myEvent.GetURL());
+            urlText->SetValue(myEvent.GetURL());
         }
         else if (myEvent.GetState() == wxWEBKIT_STATE_TRANSFERRING){
             GetStatusBar()->SetStatusText(_("Loading ") + myEvent.GetURL());
         }
         else if (myEvent.GetState() == wxWEBKIT_STATE_TRANSFERRING){
             GetStatusBar()->SetStatusText(_("Loading ") + myEvent.GetURL());
index 2284be56a89a9de026f707c9483a6ed20e1ee0c1..53e4c8438d99392868dfee744439d8d805e3eec7 100755 (executable)
@@ -284,7 +284,7 @@ void wxWebKitCtrl::OnSize(wxSizeEvent &event){
 - (void)webView:(WebView *)sender didCommitLoadForFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
 - (void)webView:(WebView *)sender didCommitLoadForFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
-        NSString *url = [[[[frame provisionalDataSource] request] URL] absoluteString];
+        NSString *url = [[[[frame dataSource] request] URL] absoluteString];
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_TRANSFERRING);
         thisEvent.SetURL( wxStringWithNSString( url ) );
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_TRANSFERRING);
         thisEvent.SetURL( wxStringWithNSString( url ) );
@@ -295,7 +295,7 @@ void wxWebKitCtrl::OnSize(wxSizeEvent &event){
 - (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
 - (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
-        NSString *url = [[[[frame provisionalDataSource] request] URL] absoluteString];
+        NSString *url = [[[[frame dataSource] request] URL] absoluteString];
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_STOP);
         thisEvent.SetURL( wxStringWithNSString( url ) );
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_STOP);
         thisEvent.SetURL( wxStringWithNSString( url ) );
@@ -306,7 +306,7 @@ void wxWebKitCtrl::OnSize(wxSizeEvent &event){
 - (void)webView:(WebView *)sender didFailLoadWithError:(NSError*) error forFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
 - (void)webView:(WebView *)sender didFailLoadWithError:(NSError*) error forFrame:(WebFrame *)frame
 {
     if (frame == [sender mainFrame]){
-        NSString *url = [[[[frame provisionalDataSource] request] URL] absoluteString];
+        NSString *url = [[[[frame dataSource] request] URL] absoluteString];
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_FAILED);
         thisEvent.SetURL( wxStringWithNSString( url ) );
         wxWebKitStateChangedEvent thisEvent(webKitWindow);
         thisEvent.SetState(wxWEBKIT_STATE_FAILED);
         thisEvent.SetURL( wxStringWithNSString( url ) );