• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Strange Webview Problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Strange Webview Problem


  • Subject: Strange Webview Problem
  • From: "Diez B. Roggisch" <email@hidden>
  • Date: Tue, 13 Jan 2009 00:10:17 +0100

Hi all,

a year ago, I developed a PyObjC application under Tiger that used WebView to implement a kind of kiosk-system. Very simple, all in all 20 lines of actual code.

Now, on two Leopard-machines, the program stopped working. The behavior is strange - the view simply stays blank.

I tried to re-implement the app with XCode 3.1 & it's new Python Cocoa templates. No change.

Now I even created a ObjectiveC-app, see the code below.

This I see in the console:

12.01.09 22:21:10 WebKitTest[1305] awakeFromNib
12.01.09 22:21:11 WebKitTest[1305] gotoMain:
12.01.09 22:21:11 WebKitTest[1305] NSConcreteNotification 0x1172d0 {name = WebProgressStartedNotification; object = <WebView: 0x129010>}
12.01.09 22:21:11 WebKitTest[1305] NSConcreteNotification 0x1172d0 {name = WebProgressEstimateChangedNotification; object = <WebView: 0x129010>}
12.01.09 22:21:11 WebKitTest[1305] progress: 1.000000
12.01.09 22:21:11 WebKitTest[1305] NSConcreteNotification 0x1172d0 {name = WebProgressFinishedNotification; object = <WebView: 0x129010>}
12.01.09 22:21:11 WebKitTest[1305] progress: 0.000000



So... it seems as if everything is working, just not the display itself :(

I'm pretty desperate here, as I need this App working till the end of the week...

So *any* suggestions are more than welcome!

Regards,

Diez B. Roggisch

//
//  WebKitTestAppDelegate.m
//  WebKitTest
//
//  Created by Diez Roggisch on 12.01.09.
//  Copyright 2009 __MyCompanyName__. All rights reserved.
//

#import "WebKitTestAppDelegate.h"


@implementation WebKitTestAppDelegate


-(IBAction) gotoMain:(id)sender { NSLog(@"gotoMain:"); NSURLRequest *req; NSURL *url; WebFrame *mf = [webView mainFrame];

    url = [NSURL URLWithString: @"http://www.spiegel.de";];
    req = [NSURLRequest requestWithURL: url
                        cachePolicy: NSURLRequestReloadIgnoringCacheData
                        timeoutInterval: 0
           ];
    [mf loadRequest: req];

}

- (void)awakeFromNib {
NSLog(@"awakeFromNib");
NSNotificationCenter *nc = [NSNotificationCenter defaultCenter];
[nc addObserver: self selector:@selector(monitorNotification:) name: WebViewProgressEstimateChangedNotification object: webView];
[nc addObserver: self selector:@selector(monitorNotification:) name: WebViewProgressStartedNotification object: webView];
[nc addObserver: self selector:@selector(monitorNotification:) name: WebViewProgressFinishedNotification object: webView];
}


- (void)monitorNotification:(id)sender {
NSLog(@"%@", sender);
NSNotification *n = (NSNotification*)sender;
if([[n name] isEqualToString: WebViewProgressEstimateChangedNotification]) {
NSLog(@"progress: %f", [webView estimatedProgress]);
}
if([[n name] isEqualToString: WebViewProgressFinishedNotification]) {
NSLog(@"progress: %f", [webView estimatedProgress]);
}



} @end _______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Strange Webview Problem
      • From: "Diez B. Roggisch" <email@hidden>
  • Prev by Date: Re: Disabled button looks like enabled
  • Next by Date: Re: @loader_path and @executable_path
  • Previous by thread: Re: NumberFormatter Defaulting all values when input incorrect
  • Next by thread: Re: Strange Webview Problem
  • Index(es):
    • Date
    • Thread