Changeset 3610

Show
Ignore:
Timestamp:
03/10/07 18:23:59 (2 years ago)
Author:
timothy
Message:

Fixes the chat room topic not showing on join.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Panels/JVChatRoomPanel.m

    r3597 r3610  
    14641464        } 
    14651465 
    1466         NSArray *args = [NSArray arrayWithObjects:topicString, ( author ? [author title] : [[[self target] topicAuthor] displayName] ), [NSNumber numberWithBool:emptyTopic], nil]; 
     1466        id authorArg = ( author ? [author title] : [[[self target] topicAuthor] displayName] ); 
     1467        NSArray *args = [NSArray arrayWithObjects:topicString, ( authorArg ? authorArg : [NSNull null] ), [NSNumber numberWithBool:emptyTopic], nil]; 
    14671468        [[display windowScriptObject] callWebScriptMethod:@"changeTopic" withArguments:args]; 
    14681469} 
     
    14801481        } 
    14811482 
    1482         NSArray *args = [NSArray arrayWithObjects:topicString, ( author ? [author title] : [[[self target] topicAuthor] displayName] ), [NSNumber numberWithBool:emptyTopic], nil]; 
     1483        id authorArg = ( author ? [author title] : [[[self target] topicAuthor] displayName] ); 
     1484        NSArray *args = [NSArray arrayWithObjects:topicString, ( authorArg ? authorArg : [NSNull null] ), [NSNumber numberWithBool:emptyTopic], nil]; 
    14831485        [[display windowScriptObject] callWebScriptMethod:@"changeTopic" withArguments:args];    
    14841486} 
  • trunk/Resources/roomTopicBanner.js

    r3569 r3610  
    3030        topicMessage = document.getElementById( 'topicMessage' ); 
    3131        topicMessage.innerHTML = topic; 
    32         topicMessage.title = topicMessage.innerText + ' set by ' + author
     32        topicMessage.title = topicMessage.innerText + ( author ? ' set by ' + author : '' )
    3333        refreshTopicSize(); 
    3434} 
  • trunk/Views/JVStyleView.m

    r3608 r3610  
    383383- (void) addBanner:(NSString *) name { 
    384384        if( ! _mainFrameReady ) { 
    385                 [self performSelector:_cmd withObject:name afterDelay:0.5]; 
     385                [self performSelector:_cmd withObject:name afterDelay:0.]; 
    386386                return; 
    387387        }