| | @@ -2152,29 +2152,5 @@ |
| 2152 | 2152 | gboolean |
| 2153 | 2153 | KzMozWrapper::SetZoomOnDocShell (float aZoom, nsIDocShell *DocShell) |
| 2154 | 2154 | { |
| 2155 | | -#ifndef G_OS_WIN32 |
| 2156 | | - nsCOMPtr<nsPresContext> PresContext; |
| 2157 | | - nsresult rv = DocShell->GetPresContext (getter_AddRefs(PresContext)); |
| 2158 | | - if (NS_FAILED(rv) || !PresContext) return FALSE; |
| 2159 | | - |
| 2160 | | - nsIDeviceContext *DeviceContext(nsnull); |
| 2161 | | - DeviceContext = PresContext->DeviceContext(); |
| 2162 | | - if (!DeviceContext) return FALSE; |
| 2163 | | - |
| 2164 | | - nsCOMPtr<nsIContentViewer> ContentViewer; |
| 2165 | | - |
| 2166 | | - rv = DocShell->GetContentViewer(getter_AddRefs(ContentViewer)); |
| 2167 | | - if (NS_FAILED(rv) || !ContentViewer) return FALSE; |
| 2168 | | - |
| 2169 | | - nsCOMPtr<nsIMarkupDocumentViewer> mdv = do_QueryInterface(ContentViewer); |
| 2170 | | - if (!mdv) return FALSE; |
| 2171 | | - |
| 2172 | | - rv = mdv->SetTextZoom (aZoom); |
| 2173 | | - |
| 2174 | | - if NS_FAILED(rv) return FALSE; |
| 2175 | | - |
| 2176 | | - return TRUE; |
| 2177 | | -#else |
| 2178 | | - return FALSE; |
| 2179 | | -#endif |
| 2155 | + return NS_SUCCEEDED(mDOMWindow->SetTextZoom(aZoom)); |
| 2180 | 2156 | } |