mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-26 22:30:56 +00:00
Minor tidying
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3435 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0ee2f21566
commit
01ac1e8035
2 changed files with 39 additions and 33 deletions
|
@ -62,8 +62,10 @@
|
||||||
+ (void)initialize
|
+ (void)initialize
|
||||||
{
|
{
|
||||||
if (self == [NSPanel class])
|
if (self == [NSPanel class])
|
||||||
|
{
|
||||||
[self setVersion:1];
|
[self setVersion:1];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Instance methods
|
// Instance methods
|
||||||
|
@ -116,7 +118,7 @@ int style = NSTitledWindowMask | NSClosableWindowMask;
|
||||||
//*****************************************************************************
|
//*****************************************************************************
|
||||||
|
|
||||||
#define PANX 362.0
|
#define PANX 362.0
|
||||||
#define PANY 191.0
|
#define PANY 161.0
|
||||||
|
|
||||||
@class GSAlertPanel;
|
@class GSAlertPanel;
|
||||||
|
|
||||||
|
@ -152,8 +154,10 @@ static GSAlertPanel *reusableAlertPanel = nil;
|
||||||
+ (void)initialize
|
+ (void)initialize
|
||||||
{
|
{
|
||||||
if (self == [GSAlertPanel class])
|
if (self == [GSAlertPanel class])
|
||||||
|
{
|
||||||
[self setVersion:1];
|
[self setVersion:1];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
- (void) buttonAction: (id)sender
|
- (void) buttonAction: (id)sender
|
||||||
{
|
{
|
||||||
|
@ -215,6 +219,7 @@ static GSAlertPanel *reusableAlertPanel = nil;
|
||||||
if (self)
|
if (self)
|
||||||
{
|
{
|
||||||
NSView *content;
|
NSView *content;
|
||||||
|
NSImage *image;
|
||||||
unsigned bs = 10.0; /* Inter-button space */
|
unsigned bs = 10.0; /* Inter-button space */
|
||||||
unsigned bh = 24.0; /* Button height. */
|
unsigned bh = 24.0; /* Button height. */
|
||||||
unsigned bw = 72.0; /* Button width. */
|
unsigned bw = 72.0; /* Button width. */
|
||||||
|
@ -280,8 +285,8 @@ static GSAlertPanel *reusableAlertPanel = nil;
|
||||||
[icoButton setBordered: NO];
|
[icoButton setBordered: NO];
|
||||||
[icoButton setEnabled: NO];
|
[icoButton setEnabled: NO];
|
||||||
[icoButton setImagePosition: NSImageOnly];
|
[icoButton setImagePosition: NSImageOnly];
|
||||||
[icoButton setImage:
|
image = [[NSApplication sharedApplication] applicationIconImage];
|
||||||
[[NSApplication sharedApplication] applicationIconImage]];
|
[icoButton setImage: image];
|
||||||
|
|
||||||
rect.size.height = 36.0;
|
rect.size.height = 36.0;
|
||||||
rect.size.width = 344.0;
|
rect.size.width = 344.0;
|
||||||
|
@ -294,6 +299,7 @@ static GSAlertPanel *reusableAlertPanel = nil;
|
||||||
[messageField setSelectable: NO];
|
[messageField setSelectable: NO];
|
||||||
[messageField setBordered: NO];
|
[messageField setBordered: NO];
|
||||||
[messageField setDrawsBackground: NO];
|
[messageField setDrawsBackground: NO];
|
||||||
|
[messageField setAlignment: NSCenterTextAlignment];
|
||||||
[messageField setStringValue: @""];
|
[messageField setStringValue: @""];
|
||||||
[messageField setFont: [NSFont systemFontOfSize: 14.0]];
|
[messageField setFont: [NSFont systemFontOfSize: 14.0]];
|
||||||
|
|
||||||
|
|
|
@ -643,12 +643,12 @@ PSMatrix* matrix;
|
||||||
changey = [super_view bounds].size.height - oldSize.height;
|
changey = [super_view bounds].size.height - oldSize.height;
|
||||||
|
|
||||||
// adjust the X axis
|
// adjust the X axis
|
||||||
fprintf (stderr, "NSView resizeWithOldSuperviewSize: \n");
|
// fprintf (stderr, "NSView resizeWithOldSuperviewSize: \n");
|
||||||
fprintf (stderr, "Change x,y (%1.2f, %1.2f)\n", changex, changey);
|
// fprintf (stderr, "Change x,y (%1.2f, %1.2f)\n", changex, changey);
|
||||||
fprintf (stderr,
|
// fprintf (stderr,
|
||||||
"NSView: old origin (%1.2f, %1.2f), size (%1.2f, %1.2f)\n",
|
// "NSView: old origin (%1.2f, %1.2f), size (%1.2f, %1.2f)\n",
|
||||||
frame.origin.x, frame.origin.y,
|
// frame.origin.x, frame.origin.y,
|
||||||
frame.size.width, frame.size.height);
|
// frame.size.width, frame.size.height);
|
||||||
|
|
||||||
if (changex)
|
if (changex)
|
||||||
{
|
{
|
||||||
|
@ -742,10 +742,10 @@ PSMatrix* matrix;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fprintf (stderr,
|
// fprintf (stderr,
|
||||||
"NSView: new origin (%1.2f, %1.2f), size (%1.2f, %1.2f)\n",
|
// "NSView: new origin (%1.2f, %1.2f), size (%1.2f, %1.2f)\n",
|
||||||
frame.origin.x, frame.origin.y,
|
// frame.origin.x, frame.origin.y,
|
||||||
frame.size.width, frame.size.height);
|
// frame.size.width, frame.size.height);
|
||||||
|
|
||||||
/* FIXME
|
/* FIXME
|
||||||
* The lines containing 'floor()' ensure that the frame sizes are an integer
|
* The lines containing 'floor()' ensure that the frame sizes are an integer
|
||||||
|
|
Loading…
Reference in a new issue