Apply clang-format

presentation
Ulrich Huber 7 years ago
parent a0644e12c9
commit 462cb85558
  1. 11
      src/gui/XournalppCursor.cpp

@ -458,9 +458,10 @@ GdkCursor* XournalppCursor::createHighlighterOrPenCursor(int size, double alpha)
int width = size;
//create a hash of variables so we notice if one changes despite being the same cursor type:
gulong flavour = (big?1:0) | (bright?2:0) | (gulong)(64*alpha)<<2 | (gulong)size<<9 | (gulong)rgb<<14;
gulong flavour =
(big ? 1 : 0) | (bright ? 2 : 0) | (gulong)(64 * alpha) << 2 | (gulong) size << 9 | (gulong) rgb << 14;
if (flavour != this->currentCursorFlavour)
{
g_warning("Not the same Flavour!");
@ -583,8 +584,8 @@ GdkCursor* XournalppCursor::createCustomDrawDirCursor(int size, bool shift, bool
bool big = control->getSettings()->isShowBigCursor();
bool bright = control->getSettings()->isHighlightPosition();
int newCursorID = CRSR_DRAWDIRNONE + (shift?1:0) + (ctrl?2:0);
gulong flavour = (big?1:0) | (bright?2:0) | (gulong)size<<2; // hash of variables for comparison only
int newCursorID = CRSR_DRAWDIRNONE + (shift?1:0) + (ctrl?2:0);
gulong flavour = (big ? 1 : 0) | (bright ? 2 : 0) | (gulong) size << 2; // hash of variables for comparison only
if (newCursorID == this->currentCursor && flavour == this->currentCursorFlavour) return NULL;
this->currentCursor = newCursorID;

Loading…
Cancel
Save