Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

hide scroller surely

  • Loading branch information...
commit 007b151f14dc4ab98a0567d3abdd098d287d02c3 1 parent 90b3511
@psychs psychs authored
View
1  Classes/Views/Log/LogController.h
@@ -22,7 +22,6 @@
LogPolicy* policy;
LogScriptEventSink* sink;
MarkedScroller* scroller;
- WebScriptObject* js;
WebViewAutoScroll* autoScroller;
IRCWorld* world;
View
10 Classes/Views/Log/LogController.m
@@ -68,7 +68,6 @@ - (void)dealloc
[policy release];
[sink release];
[scroller release];
- [js release];
[autoScroller release];
[menu release];
@@ -817,6 +816,7 @@ - (void)setUpScroller
if ([scrollView respondsToSelector:@selector(setAllowsHorizontalScrolling:)]) {
[(id)scrollView setAllowsHorizontalScrolling:NO];
}
+ [[view windowScriptObject] evaluateWebScript:@"document.body.style.overflowX='hidden';"];
NSScroller* old = [scrollView verticalScroller];
if (old && ![old isKindOfClass:[MarkedScroller class]]) {
@@ -838,9 +838,7 @@ - (void)setUpScroller
- (void)webView:(WebView *)sender didClearWindowObject:(WebScriptObject *)windowObject forFrame:(WebFrame *)frame
{
- [js release];
- js = [windowObject retain];
- [js setValue:sink forKey:@"app"];
+ [[view windowScriptObject] setValue:sink forKey:@"app"];
}
- (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame
@@ -945,11 +943,11 @@ - (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame
];
}
- [js evaluateWebScript:s];
+ [[view windowScriptObject] evaluateWebScript:s];
// evaluate theme js
if (theme.js.content.length) {
- [js evaluateWebScript:theme.js.content];
+ [[view windowScriptObject] evaluateWebScript:theme.js.content];
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.