Commit 25f453ef authored by Julien Nabet's avatar Julien Nabet Committed by Albert Astals Cid

Prefer prefix ++/-- operators for non-primitive types

Part of bug #80537
parent ed01688a
......@@ -7,6 +7,7 @@
// Copyright 2009 Stefan Thomas <thomas@eload24.com>
// Copyright 2010, 2011 Hib Eris <hib@hiberis.nl>
// Copyright 2010 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2013 Julien Nabet <serval2412@yahoo.fr>
//
//========================================================================
......@@ -213,7 +214,7 @@ size_t CachedFileWriter::write(const char *ptr, size_t size)
while (len) {
if (chunks) {
if (offset == CachedFileChunkSize) {
it++;
++it;
if (it == (*chunks).end()) return written;
offset = 0;
}
......
......@@ -25,6 +25,7 @@
// Copyright (C) 2009 Ilya Gorenbein <igorenbein@finjan.com>
// Copyright (C) 2010 Hib Eris <hib@hiberis.nl>
// Copyright (C) 2012 Fabio D'Urso <fabiodurso@hotmail.it>
// Copyright (C) 2013 Julien Nabet <serval2412@yahoo.fr>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
......@@ -129,7 +130,7 @@ Catalog::~Catalog() {
delete kidsIdxList;
if (attrsList) {
std::vector<PageAttrs *>::iterator it;
for (it = attrsList->begin() ; it < attrsList->end(); it++ ) {
for (it = attrsList->begin() ; it != attrsList->end(); ++it ) {
delete *it;
}
delete attrsList;
......@@ -137,7 +138,7 @@ Catalog::~Catalog() {
delete pagesRefList;
if (pagesList) {
std::vector<Dict *>::iterator it;
for (it = pagesList->begin() ; it < pagesList->end(); it++ ) {
for (it = pagesList->begin() ; it != pagesList->end(); ++it ) {
if (!(*it)->decRef()) {
delete *it;
}
......
......@@ -25,6 +25,7 @@
// Copyright (C) 2011 Stephen Reichling <sreichling@chegg.com>
// Copyright (C) 2012 Igor Slepchin <igor.slepchin@gmail.com>
// Copyright (C) 2012 Luis Parravicini <lparravi@gmail.com>
// Copyright (C) 2013 Julien Nabet <serval2412@yahoo.fr>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
......@@ -297,7 +298,7 @@ HtmlFontAccu::~HtmlFontAccu(){
int HtmlFontAccu::AddFont(const HtmlFont& font){
std::vector<HtmlFont>::iterator i;
for (i=accu->begin();i!=accu->end();i++)
for (i=accu->begin();i!=accu->end();++i)
{
if (font.isEqual(*i))
{
......
......@@ -19,6 +19,7 @@
//
// Copyright (C) 2008 Boris Toloknov <tlknv@yandex.ru>
// Copyright (C) 2010 Albert Astals Cid <aacid@kde.org>
// Copyright (C) 2013 Julien Nabet <serval2412@yahoo.fr>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
......@@ -128,7 +129,7 @@ HtmlLinks::~HtmlLinks(){
GBool HtmlLinks::inLink(double xmin,double ymin,double xmax,double ymax,int& p)const {
for(std::vector<HtmlLink>::iterator i=accu->begin();i!=accu->end();i++){
for(std::vector<HtmlLink>::iterator i=accu->begin();i!=accu->end();++i){
if (i->inLink(xmin,ymin,xmax,ymax)) {
p=(i - accu->begin());
return 1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment