diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-06-09 11:42:41 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-06-09 12:10:45 +0200 |
commit | 3a1a5b9744eb73f82c28ecfaa39b54587ef8206b (patch) | |
tree | 79acfdfb87e08645a92f8d0b147bb151d81565d9 /libreofficekit | |
parent | 9805ae85eb776fa8f718c1415942c31f2cfc6d9e (diff) |
-Werror,-Wunused-private-field
Change-Id: I76cf487c66e048b5e9d0877a1b690cd066b73528
Diffstat (limited to 'libreofficekit')
-rw-r--r-- | libreofficekit/source/gtk/lokdocview.cxx | 10 | ||||
-rw-r--r-- | libreofficekit/source/gtk/tilebuffer.hxx | 4 |
2 files changed, 3 insertions, 11 deletions
diff --git a/libreofficekit/source/gtk/lokdocview.cxx b/libreofficekit/source/gtk/lokdocview.cxx index 5f768e74a400..7e50b96b9d75 100644 --- a/libreofficekit/source/gtk/lokdocview.cxx +++ b/libreofficekit/source/gtk/lokdocview.cxx @@ -274,7 +274,7 @@ LOKDocView_Impl::CallbackData::CallbackData(int nType, const std::string& rPaylo LOKDocView_Impl::LOKDocView_Impl(LOKDocView* pDocView) : m_pDocView(pDocView), m_pDrawingArea(gtk_drawing_area_new()), - m_aTileBuffer(TileBuffer(0,0,0)), + m_aTileBuffer(TileBuffer(0,0)), m_fZoom(1), m_pOffice(0), m_pDocument(0), @@ -1230,13 +1230,11 @@ SAL_DLLPUBLIC_EXPORT gboolean lok_doc_view_open_document( LOKDocView* pDocView, long nDocumentHeightTwips = pDocView->m_pImpl->m_nDocumentHeightTwips; long nDocumentWidthPixels = twipToPixel(nDocumentWidthTwips, zoom); long nDocumentHeightPixels = twipToPixel(nDocumentHeightTwips, zoom); - // Total number of rows / columns in this document. - guint nRows = ceil((double)nDocumentHeightPixels / nTileSizePixels); + // Total number of columns in this document. guint nColumns = ceil((double)nDocumentWidthPixels / nTileSizePixels); pDocView->m_pImpl->m_aTileBuffer = TileBuffer(pDocView->m_pImpl->m_pDocument, - nRows, nColumns); gtk_widget_set_size_request(pDocView->m_pImpl->m_pDrawingArea, nDocumentWidthPixels, @@ -1257,12 +1255,10 @@ SAL_DLLPUBLIC_EXPORT void lok_doc_view_set_zoom ( LOKDocView* pDocView, float fZ pDocView->m_pImpl->m_fZoom = fZoom; long nDocumentWidthPixels = twipToPixel(pDocView->m_pImpl->m_nDocumentWidthTwips, fZoom); long nDocumentHeightPixels = twipToPixel(pDocView->m_pImpl->m_nDocumentHeightTwips, fZoom); - // Total number of rows / columns in this document. - guint nRows = ceil((double)nDocumentHeightPixels / nTileSizePixels); + // Total number of columns in this document. guint nColumns = ceil((double)nDocumentWidthPixels / nTileSizePixels); pDocView->m_pImpl->m_aTileBuffer = TileBuffer(pDocView->m_pImpl->m_pDocument, - nRows, nColumns); gtk_widget_set_size_request(pDocView->m_pImpl->m_pDrawingArea, nDocumentWidthPixels, diff --git a/libreofficekit/source/gtk/tilebuffer.hxx b/libreofficekit/source/gtk/tilebuffer.hxx index ea8e52452c8d..b9bf71b950d5 100644 --- a/libreofficekit/source/gtk/tilebuffer.hxx +++ b/libreofficekit/source/gtk/tilebuffer.hxx @@ -83,11 +83,9 @@ class TileBuffer { public: TileBuffer(LibreOfficeKitDocument *document, - int rows, int columns) : m_pLOKDocument(document) , m_nWidth(columns) - , m_nHeight(rows) { } ~TileBuffer() {} @@ -126,8 +124,6 @@ class TileBuffer std::map<int, Tile> m_mTiles; /// Width of the current tile buffer (number of columns) int m_nWidth; - /// Height of the current tile buffer (numbero of rows) - int m_nHeight; }; #endif // INCLUDED_TILEBUFFER_HXX |