diff options
author | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-09-26 13:08:56 +0000 |
---|---|---|
committer | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-09-26 13:08:56 +0000 |
commit | 373ebc634573364c27b1ebd35bb537ef1285cba4 (patch) | |
tree | de677b3d81e81875c85dee3c838959425057a9f7 /src/views/animated/SkStaticTextView.cpp | |
parent | 5c83dcc371b68e4cda2d533e247684ea1a32d1bc (diff) |
Suppress some warnings on linux.
R=reed@google.com
Review URL: https://codereview.appspot.com/6572046
git-svn-id: http://skia.googlecode.com/svn/trunk@5687 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/views/animated/SkStaticTextView.cpp')
-rw-r--r-- | src/views/animated/SkStaticTextView.cpp | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/views/animated/SkStaticTextView.cpp b/src/views/animated/SkStaticTextView.cpp index 8ab11835d7..199b2fe8c5 100644 --- a/src/views/animated/SkStaticTextView.cpp +++ b/src/views/animated/SkStaticTextView.cpp @@ -154,25 +154,29 @@ if (false) { // avoid bit rot, suppress warning this->INHERITED::onInflate(dom, node); int index; - if ((index = dom.findList(node, "mode", "fixed,auto-width,auto-height")) >= 0) + if ((index = dom.findList(node, "mode", "fixed,auto-width,auto-height")) >= 0) { this->setMode((Mode)index); - else + } else { assert_no_attr(dom, node, "mode"); + } - if ((index = dom.findList(node, "spacing-align", "start,center,end")) >= 0) + if ((index = dom.findList(node, "spacing-align", "start,center,end")) >= 0) { this->setSpacingAlign((SkTextBox::SpacingAlign)index); - else + } else { assert_no_attr(dom, node, "spacing-align"); + } SkScalar s[2]; - if (dom.findScalars(node, "margin", s, 2)) + if (dom.findScalars(node, "margin", s, 2)) { this->setMargin(s[0], s[1]); - else + } else { assert_no_attr(dom, node, "margin"); + } const char* text = dom.findAttr(node, "text"); - if (text) + if (text) { this->setText(text); + } if ((node = dom.getFirstChild(node, "paint")) != NULL && (node = dom.getFirstChild(node, "screenplay")) != NULL) |