Changeset 3661

Show
Ignore:
Timestamp:
06/18/07 01:31:55 (1 year ago)
Author:
rinoa
Message:

Allows the topic to show more lines if the window is smaller. New limit of 6 lines. #533

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Resources/roomTopicBanner.js

    r3610 r3661  
    55        if( e && e.altKey ) { 
    66                topicSize++; 
    7                 if( topicSize > 3 ) topicSize = 0; 
    8                 topicAreaSize = ( ! topicSize ? 17 : ( topicSize == 1 ? 32 : ( topicSize == 2 ? 47 : 62 ) ) ); 
    9                 if( topicSize == 3 ) document.getElementById( 'toggleButton' ).className = "up"; 
     7                if( topicSize > 6 ) topicSize = 0; 
     8                topicAreaSize = ( ! topicSize ? 17 : ( topicSize == 1 ? 32 : ( topicSize == 2 ? 47 : ( topicSize == 3 ? 62 : ( topicSize == 4 ? 77 : ( topicSize == 5 ? 92 : 107 ) ) ) ) ) ); 
     9                if( topicSize == 6 ) document.getElementById( 'toggleButton' ).className = "up"; 
    1010                else document.getElementById( 'toggleButton' ).className = ""; 
    1111        } else { 
    12                 if( ! topicToggled && topicSize < 3 ) { 
     12                if( ! topicToggled && topicSize < 6 ) { 
    1313                        topicAreaSize = document.getElementById( 'topicMessage' ).clientHeight + 2; 
    14                         if( topicAreaSize > 62 ) topicAreaSize = 62
     14                        if( topicAreaSize > 107 ) topicAreaSize = 107
    1515                        else if( topicAreaSize < 17 ) topicAreaSize = 17; 
    1616                        document.getElementById( 'toggleButton' ).className = "up"; 
    1717                        topicToggled = true; 
    1818                } else { 
    19                         if( topicSize == 3 ) topicSize = 0; 
    20                         topicAreaSize = ( ! topicSize ? 17 : ( topicSize == 1 ? 32 : ( topicSize == 2 ? 47 : 62 ) ) ); 
     19                        if( topicSize == 6 ) topicSize = 0; 
     20                        topicAreaSize = ( ! topicSize ? 17 : ( topicSize == 1 ? 32 : ( topicSize == 2 ? 47 : ( topicSize == 3 ? 62 : ( topicSize == 4 ? 77 : ( topicSize == 5 ? 92 : 107 ) ) ) ) ) ); 
    2121                        document.getElementById( 'toggleButton' ).className = ""; 
    2222                        topicToggled = false; 
     
    4141        if( topicToggled ) { 
    4242                topicAreaSize = topicMessage.clientHeight + 2; 
    43                 if( topicAreaSize > 62 ) topicAreaSize = 62
     43                if( topicAreaSize > 107 ) topicAreaSize = 107
    4444                else if( topicAreaSize < 17 ) topicAreaSize = 17; 
    4545                document.getElementById( 'topicArea' ).style.setProperty( 'height', topicAreaSize + 'px', null );