Changeset 814 for trunk/macosx/MessageWindowController.m
- Timestamp:
- Aug 22, 2006, 1:59:46 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/macosx/MessageWindowController.m
r813 r814 99 99 100 100 NSString * levelString; 101 101 102 102 if (level == TR_MSG_ERR) 103 103 levelString = @"ERR"; … … 110 110 111 111 NSAttributedString * messageString = [[[NSAttributedString alloc] initWithString: 112 [NSString stringWithFormat: @"%@: %s\n", levelString, message]] autorelease]; 112 [NSString stringWithFormat: @"(%@ %@) %s\n", [[NSDate date] dateWithCalendarFormat: @"%Y-%m-%d %H:%M:%S.%F" 113 timeZone: nil], levelString, message]] autorelease]; 113 114 114 115 [fLock lock]; … … 124 125 return; 125 126 127 [fLock lock]; 128 126 129 //keep scrolled to bottom if already at bottom or there is no scroll bar yet 127 130 BOOL shouldScroll = NO; … … 129 132 if ([scroller floatValue] == 1.0 || [scroller isHidden] || [scroller knobProportion] == 1.0) 130 133 shouldScroll = YES; 131 132 [fLock lock];133 134 134 135 NSEnumerator * enumerator = [fBufferArray objectEnumerator]; … … 138 139 [fBufferArray removeAllObjects]; 139 140 140 [f Lock unlock];141 [fTextView setFont: [NSFont fontWithName: @"Monaco" size: 10]]; //find a way to set this permanently 141 142 142 143 if (shouldScroll) 143 144 [fTextView scrollRangeToVisible: NSMakeRange([[fTextView string] length], 0)]; 145 146 [fLock unlock]; 144 147 } 145 148
Note: See TracChangeset
for help on using the changeset viewer.