<html>
    <head>
      <base href="https://bugs.webkit.org/">
    </head>
    <body><span class="vcard"><a class="email" href="mailto:nvasilyev@apple.com" title="Nikita Vasilyev <nvasilyev@apple.com>"> <span class="fn">Nikita Vasilyev</span></a>
</span> changed
          <a class="bz_bug_link 
          bz_status_ASSIGNED "
   title="ASSIGNED - Uncaught Exception: TypeError: this._textEditor.toggleUnexecutedCodeHighlights().then is not a function"
   href="https://bugs.webkit.org/show_bug.cgi?id=181912">bug 181912</a>
          <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>NEW
           </td>
           <td>ASSIGNED
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Assignee</td>
           <td>webkit-unassigned@lists.webkit.org
           </td>
           <td>nvasilyev@apple.com
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_ASSIGNED "
   title="ASSIGNED - Uncaught Exception: TypeError: this._textEditor.toggleUnexecutedCodeHighlights().then is not a function"
   href="https://bugs.webkit.org/show_bug.cgi?id=181912#c2">Comment # 2</a>
              on <a class="bz_bug_link 
          bz_status_ASSIGNED "
   title="ASSIGNED - Uncaught Exception: TypeError: this._textEditor.toggleUnexecutedCodeHighlights().then is not a function"
   href="https://bugs.webkit.org/show_bug.cgi?id=181912">bug 181912</a>
              from <span class="vcard"><a class="email" href="mailto:nvasilyev@apple.com" title="Nikita Vasilyev <nvasilyev@apple.com>"> <span class="fn">Nikita Vasilyev</span></a>
</span></b>
        <pre>This is poorly architectured (likely by me 3 years ago).

The [c] icon can only have 3 states:
- gray: disabled, can't be activated.
- black: not activated.
- blue: activated.

The icon updates on setting change. The setting can only have two states:
- enabled.
- disabled.

The setting change is used to update the icon state. Which is wrong, it doesn't even have all 3 states.

The setting should only indicate user preference: enabled (when possible) and disabled.

Instead, the setting is user as a communication channel to set the icon to deactivated state. Currently, the setting gets set to disabled when:
- Enabling pretty-print.
- Editing a script.

Pretty-printing and editing shouldn't change the setting, yet these actions should set the icon to disabled state.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>