why can not get the configuration of AdiumMessageWindow toolbar
Chen Ze
surfchen at gmail.com
Fri May 7 04:03:18 UTC 2010
On Fri, May 7, 2010 at 11:56 AM, Peter Hosey <boredzo at adium.im> wrote:
> On May 6, 2010, at 20:54:53, Chen Ze wrote:
>> But the result I got is not what I expected.
>
> What did you expect?
>
Below is the code getting from adium's source code, which do the
config for that toolbar.
- (void)_configureToolbar
{
// NSToolbar *toolbar; change this if need be
toolbar = [[[NSToolbar alloc]
initWithIdentifier:TOOLBAR_MESSAGE_WINDOW] autorelease];
[toolbar setDelegate:self];
[toolbar setDisplayMode:NSToolbarDisplayModeIconOnly];
[toolbar setSizeMode:NSToolbarSizeModeSmall];
[toolbar setVisible:YES];
[toolbar setAllowsUserCustomization:YES];
[toolbar setAutosavesConfiguration:YES];
//
toolbarItems = [[[adium toolbarController]
toolbarItemsForToolbarTypes:[NSArray arrayWithObjects:@"General",
@"ListObject", @"TextEntry", @"MessageWindow", nil]] retain];
As we can see ,the sizemode is NSToolbarSizeModeSmall. And the
NSToolbarSizeModeSmall is not 1(see below), but the in the xml, the
value below <key>TB Size Mode</key> is 1.
typedef enum {
NSToolbarSizeModeDefault,
NSToolbarSizeModeRegular,
NSToolbarSizeModeSmall
} NSToolbarSizeMode;
>
>
--
aka Surf Chen
http://chenze.name/
More information about the devel
mailing list