Index: trunk/extensions/SemanticMediaWiki/includes/SMW_DataValue.php |
— | — | @@ -396,6 +396,11 @@ |
397 | 397 | * |
398 | 398 | * @param string $value |
399 | 399 | * @param string $comparator |
| 400 | + * |
| 401 | + * TODO: It would be better to have an associative array that maps comparator strings |
| 402 | + * to their internal meaning, so this switch and the reverse one in SMWValueDescription |
| 403 | + * can be thrown away. This would allow to extend the comparators more easily, without |
| 404 | + * breaking things. |
400 | 405 | */ |
401 | 406 | static protected function prepareValue( &$value, &$comparator ) { |
402 | 407 | global $smwgQComparators, $smwStrictComparators; |
— | — | @@ -422,10 +427,10 @@ |
423 | 428 | case '!~': |
424 | 429 | $comparator = SMW_CMP_NLKE; |
425 | 430 | break; |
426 | | - case '>=': case '≥' : |
| 431 | + case '≥' : |
427 | 432 | $comparator = SMW_CMP_GEQ; |
428 | 433 | break; |
429 | | - case '<=': case '≤' : |
| 434 | + case '≤' : |
430 | 435 | $comparator = SMW_CMP_LEQ; |
431 | 436 | break; |
432 | 437 | // default: not possible |
Index: trunk/extensions/SemanticMediaWiki/SMW_Settings.php |
— | — | @@ -203,14 +203,14 @@ |
204 | 204 | * ! (unequal to) |
205 | 205 | * ~ (pattern with '*' as wildcard, only for Type:String) |
206 | 206 | * !~ (not a pattern with '*' as wildcard, only for Type:String, need to be placed before ! and ~ to work correctly) |
207 | | - * <= or ≤(smaller than or equal to) |
208 | | - * >= or ≥(greater than or equal to) |
| 207 | + * ≤ (smaller than or equal to) |
| 208 | + * ≥ (greater than or equal to) |
209 | 209 | * |
210 | 210 | * If unsupported comparators are used, they are treated as part of the queried value |
211 | 211 | * |
212 | 212 | * @var string |
213 | 213 | */ |
214 | | -$smwgQComparators = '<|>|!~|!|~|<=|>=|≤|≥'; |
| 214 | +$smwgQComparators = '<|>|!~|!|~|≤|≥'; |
215 | 215 | |
216 | 216 | ### |
217 | 217 | # Sets whether the > and < comparators should be strict or not. If they are strict, |