Bug 1258789 - Add binary logic operators for WhitespaceAround. r=grisha

MozReview-Commit-ID: 12BUCUmassJ

--HG--
extra : rebase_source : c414f36187da86390b633357232c883668f9afe1
This commit is contained in:
Michael Comella 2016-04-12 18:10:55 -07:00
Родитель 30fdaa2a6c
Коммит 6ea08620c8
3 изменённых файлов: 3 добавлений и 3 удалений

Просмотреть файл

@ -54,7 +54,7 @@
<property name="tokens" value="COMMA, SEMI"/> <property name="tokens" value="COMMA, SEMI"/>
</module> </module>
<module name="WhitespaceAround"> <module name="WhitespaceAround">
<property name="tokens" value="ASSIGN"/> <property name="tokens" value="ASSIGN, BAND, BAND_ASSIGN, BOR, BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN"/>
</module> </module>
</module> </module>

Просмотреть файл

@ -121,7 +121,7 @@ class ActionModeCompat implements GeckoPopupMenu.OnMenuItemClickListener,
int yOffset = location[1] + view.getHeight() / 2; int yOffset = location[1] + view.getHeight() / 2;
Toast toast = Toast.makeText(view.getContext(), item.getTitle(), Toast.LENGTH_SHORT); Toast toast = Toast.makeText(view.getContext(), item.getTitle(), Toast.LENGTH_SHORT);
toast.setGravity(Gravity.TOP|Gravity.LEFT, xOffset, yOffset); toast.setGravity(Gravity.TOP | Gravity.LEFT, xOffset, yOffset);
toast.show(); toast.show();
} }
} }

Просмотреть файл

@ -249,7 +249,7 @@ public class LightweightTheme implements GeckoEventListener {
// Calculate the luminance to determine if it's a light or a dark theme. // Calculate the luminance to determine if it's a light or a dark theme.
double luminance = (0.2125 * ((mColor & 0x00FF0000) >> 16)) + double luminance = (0.2125 * ((mColor & 0x00FF0000) >> 16)) +
(0.7154 * ((mColor & 0x0000FF00) >> 8)) + (0.7154 * ((mColor & 0x0000FF00) >> 8)) +
(0.0721 * (mColor &0x000000FF)); (0.0721 * (mColor & 0x000000FF));
mIsLight = luminance > 110; mIsLight = luminance > 110;
// The bitmap image might be smaller than the device's width. // The bitmap image might be smaller than the device's width.