<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>72488</bug_id>
          
          <creation_ts>2011-11-16 04:35:48 -0800</creation_ts>
          <short_desc>Remove unnecessary if check from RenderListBox::paintItemForeground</short_desc>
          <delta_ts>2011-11-16 07:05:17 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebCore Misc.</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Antaryami Pandia">xqb748</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>darin</cc>
    
    <cc>tkent</cc>
    
    <cc>webkit.review.bot</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>503760</commentid>
    <comment_count>0</comment_count>
    <who name="Antaryami Pandia">xqb748</who>
    <bug_when>2011-11-16 04:35:48 -0800</bug_when>
    <thetext>There is a if check which checks for visibility before drawing text.

    if (itemStyle-&gt;visibility() != HIDDEN)
        paintInfo.context-&gt;drawBidiText(itemFont, textRun, r.location());

I think this if check is unnecessary, since there is already an early return available for the visibility and the itemStyle is not modified in between.

The early return is as follows:-
    if (itemStyle-&gt;visibility() == HIDDEN)
        return;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>503765</commentid>
    <comment_count>1</comment_count>
      <attachid>115359</attachid>
    <who name="Antaryami Pandia">xqb748</who>
    <bug_when>2011-11-16 04:40:58 -0800</bug_when>
    <thetext>Created attachment 115359
Proposed Patch

Proposed Patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>503806</commentid>
    <comment_count>2</comment_count>
      <attachid>115359</attachid>
    <who name="Andreas Kling">kling</who>
    <bug_when>2011-11-16 06:19:15 -0800</bug_when>
    <thetext>Comment on attachment 115359
Proposed Patch

r=me</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>503842</commentid>
    <comment_count>3</comment_count>
      <attachid>115359</attachid>
    <who name="WebKit Review Bot">webkit.review.bot</who>
    <bug_when>2011-11-16 07:05:13 -0800</bug_when>
    <thetext>Comment on attachment 115359
Proposed Patch

Clearing flags on attachment: 115359

Committed r100447: &lt;http://trac.webkit.org/changeset/100447&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>503843</commentid>
    <comment_count>4</comment_count>
    <who name="WebKit Review Bot">webkit.review.bot</who>
    <bug_when>2011-11-16 07:05:17 -0800</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>115359</attachid>
            <date>2011-11-16 04:40:58 -0800</date>
            <delta_ts>2011-11-16 07:05:13 -0800</delta_ts>
            <desc>Proposed Patch</desc>
            <filename>72488.txt</filename>
            <type>text/plain</type>
            <size>1292</size>
            <attacher name="Antaryami Pandia">xqb748</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwo9PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBTb3VyY2UvV2Vi
Q29yZS9DaGFuZ2VMb2cJKHJldmlzaW9uIDEwMDQzMCkKKysrIFNvdXJjZS9XZWJDb3JlL0NoYW5n
ZUxvZ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LSAgICBpZiAoaXRlbVN0eWxlLT52aXNpYmlsaXR5KCkgIT0gSElE
REVOKQotICAgICAgICBwYWludEluZm8uY29udGV4dC0+ZHJhd0JpZGlUZXh0KGl0ZW1Gb250LCB0
ZXh0UnVuLCByLmxvY2F0aW9uKCkpOworICAgIHBhaW50SW5mby5jb250ZXh0LT5kcmF3QmlkaVRl
eHQoaXRlbUZvbnQsIHRleHRSdW4sIHIubG9jYXRpb24oKSk7CiB9CiAKIHZvaWQgUmVuZGVyTGlz
dEJveDo6cGFpbnRJdGVtQmFja2dyb3VuZChQYWludEluZm8mIHBhaW50SW5mbywgY29uc3QgTGF5
b3V0UG9pbnQmIHBhaW50T2Zmc2V0LCBpbnQgbGlzdEluZGV4KQo=
</data>

          </attachment>
      

    </bug>

</bugzilla>