summaryrefslogtreecommitdiff
blob: 411341c9d1b8e0c59bb4ed8c0dc3e7d24c811b8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
Namespace qualify bind, in order to avoid clashes with boost::placeholder
Patches taken from FreeBSD:
https://svnweb.freebsd.org/ports?view=revision&revision=408592

--- scantailor-0.9.11.1/filters/deskew/Filter.cpp
+++ scantailor-0.9.11.1/filters/deskew/Filter.cpp
@@ -85,9 +85,9 @@
 	
 	QDomElement filter_el(doc.createElement("deskew"));
 	writer.enumPages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writePageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/filters/fix_orientation/Filter.cpp
+++ scantailor-0.9.11.1/filters/fix_orientation/Filter.cpp
@@ -100,9 +100,9 @@
 	
 	QDomElement filter_el(doc.createElement("fix-orientation"));
 	writer.enumImages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writeImageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/filters/output/Filter.cpp
+++ scantailor-0.9.11.1/filters/output/Filter.cpp
@@ -93,9 +93,9 @@
 	
 	QDomElement filter_el(doc.createElement("output"));
 	writer.enumPages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writePageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/filters/page_layout/Filter.cpp
+++ scantailor-0.9.11.1/filters/page_layout/Filter.cpp
@@ -136,9 +136,9 @@
 	
 	QDomElement filter_el(doc.createElement("page-layout"));
 	writer.enumPages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writePageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/filters/page_split/Filter.cpp
+++ scantailor-0.9.11.1/filters/page_split/Filter.cpp
@@ -110,9 +110,9 @@
 	);
 	
 	writer.enumImages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writeImageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/filters/select_content/Filter.cpp
+++ scantailor-0.9.11.1/filters/select_content/Filter.cpp
@@ -119,9 +119,9 @@
 	
 	QDomElement filter_el(doc.createElement("select-content"));
 	writer.enumPages(
-		bind(
+		boost::lambda::bind(
 			&Filter::writePageSettings,
-			this, boost::ref(doc), var(filter_el), _1, _2
+			this, boost::ref(doc), var(filter_el), boost::lambda::_1, boost::lambda::_2
 		)
 	);
 	
--- scantailor-0.9.11.1/MainWindow.cpp
+++ scantailor-0.9.11.1/MainWindow.cpp
@@ -1898,8 +1898,8 @@
 		ImageFileInfo image_file_info(file_info, std::vector<ImageMetadata>());
 
 		ImageMetadataLoader::Status const status = ImageMetadataLoader::load(
-			files.at(i), bind(&std::vector<ImageMetadata>::push_back,
-			boost::ref(image_file_info.imageInfo()), _1)
+			files.at(i), boost::lambda::bind(&std::vector<ImageMetadata>::push_back,
+			boost::ref(image_file_info.imageInfo()), boost::lambda::_1)
 		);
 
 		if (status == ImageMetadataLoader::LOADED) {
@@ -1921,7 +1921,7 @@
 	}
 
 	// Check if there is at least one DPI that's not OK.
-	if (std::find_if(new_files.begin(), new_files.end(), !bind(&ImageFileInfo::isDpiOK, _1)) != new_files.end()) {
+	if (std::find_if(new_files.begin(), new_files.end(), !boost::lambda::bind(&ImageFileInfo::isDpiOK, boost::lambda::_1)) != new_files.end()) {
 
 		std::auto_ptr<FixDpiDialog> dpi_dialog(new FixDpiDialog(new_files, this));
 		dpi_dialog->setWindowModality(Qt::WindowModal);
--- scantailor-0.9.11.1/ThumbnailSequence.cpp
+++ scantailor-0.9.11.1/ThumbnailSequence.cpp
@@ -491,7 +491,7 @@
 	m_pSelectionLeader(0)
 {
 	m_graphicsScene.setContextMenuEventCallback(
-		bind(&Impl::sceneContextMenuEvent, this, _1)
+		boost::lambda::bind(&Impl::sceneContextMenuEvent, this, boost::lambda::_1)
 	);
 }
 
@@ -605,7 +605,7 @@
 {
 	ItemsById::iterator const id_it(m_itemsById.find(page_info.id()));
 	if (id_it != m_itemsById.end()) {
-		m_itemsById.modify(id_it, bind(&Item::pageInfo, _1) = page_info);
+		m_itemsById.modify(id_it, boost::lambda::bind(&Item::pageInfo, boost::lambda::_1) = page_info);
 		invalidateThumbnailImpl(id_it);
 	}
 }
@@ -725,10 +725,10 @@
 	// Sort pages in m_itemsInOrder using m_ptrOrderProvider.
 	if (m_ptrOrderProvider.get()) {
 		m_itemsInOrder.sort(
-			bind(
+			boost::lambda::bind(
 				&PageOrderProvider::precedes, m_ptrOrderProvider.get(),
-				bind(&Item::pageId, _1), bind(&Item::incompleteThumbnail, _1),
-				bind(&Item::pageId, _2), bind(&Item::incompleteThumbnail, _2) 
+				boost::lambda::bind(&Item::pageId, boost::lambda::_1), bind(&Item::incompleteThumbnail, boost::lambda::_1),
+				boost::lambda::bind(&Item::pageId, boost::lambda::_2), bind(&Item::incompleteThumbnail, boost::lambda::_2) 
 			)
 		);
 	}