Re: refresh issue with QLPreviewPanel..!
Re: refresh issue with QLPreviewPanel..!
- Subject: Re: refresh issue with QLPreviewPanel..!
- From: Naresh Kongara <email@hidden>
- Date: Tue, 1 Sep 2009 10:56:00 +0530
Hi,
In snowleopard the framework is provided under quartz framework, and
some changes are made for preview panel also, i.e instead of setting
URLS we need to implement datasource methods. I had a seperate
implementation for snowleopard. This is working fine for Snowleopard.
Only issue is with leopard. ?
Any way thanks for your valuable suggestions.
Thanks,
Naresh K
On Sep 1, 2009, at 1:16 AM, Julien Jalon wrote:
Needless to say that what you do is totally unsupported and will
totally break in 10.6.
10.6 now provides a public (incompatible with Leopard) API but even
with this API, what you do is greatly unsupported (and will break in
the future). Add to that the fact QL panel is very asynchronous, and
it's expected for you to encounter a *lot* of problems.
--
Julien
On Monday, August 31, 2009, Naresh Kongara
<email@hidden> wrote:
Hi,
I have an app in which i need to display the view to be printed in
QuickLook preview. For this i thought os using the
(QlPreviewPanel)QuickLookUI.framework which is available at /System/
Library/PrivateFrameworks.
QLPreviewPanel class is obtained using
#define QLPreviewPanel NSClassFromString(@"QLPreviewPanel")
and the QuickLookUI framework is loaded as below.
[[NSBundle bundleWithPath:@"/System/Library/PrivateFrameworks/
QuickLookUI.framework"] load];
Using NSPrintOperation i'm saving the View to be printed a path say
PDFPath.
Then i'm passing the PDFPath URL to previewPanel as below.
[[QLPreviewPanel sharedPreviewPanel] setURLs:
[NSArray arrayWithObject:[NSURL fileURLWithPath:PDFPath]]];
[[QLPreviewPanel sharedPreviewPanel]
makeKeyAndOrderFront:self];
The above code is working fine for the first time. If i close the
panel and change the view to be printed(Which inturn changes the
file at PDFPath).Now if the panel is shown again with above 2
lines of code then the panel is not showing the updated one, it is
showing the previous view only.
If we wait for some time to show the panel, then it is showing the
correct view only.
There is no problem with file at PDFPath.
I don't know why the preview panel is taking the time to refresh.
If any one has the idea on it, Please let me know.
Thanks,
Naresh Kongara
email@hidden
_______________________________________________
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)http://lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
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