Mercurial > projects > dwt-mac
view dwt/internal/cocoa/NSBrowserCell.d @ 130:3d4579727e0e
Fixes #2 and #3
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Tue, 10 Feb 2009 21:01:24 +0100 |
parents | d8635bb48c7c |
children |
line wrap: on
line source
/******************************************************************************* * Copyright (c) 2000, 2008 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * IBM Corporation - initial API and implementation * * Port to the D programming language: * Jacob Carlborg <doob@me.com> *******************************************************************************/ module dwt.internal.cocoa.NSBrowserCell; import cocoa = dwt.internal.cocoa.id; import dwt.internal.cocoa.NSCell; import dwt.internal.cocoa.NSColor; import dwt.internal.cocoa.NSView; import dwt.internal.cocoa.OS; import objc = dwt.internal.objc.runtime; public class NSBrowserCell : NSCell { public this () { super(); } public this (objc.id id) { super(id); } public this (cocoa.id id) { super(id); } public NSColor highlightColorInView (NSView controlView) { objc.id result = OS.objc_msgSend(this.id, OS.sel_highlightColorInView_, controlView !is null ? controlView.id : null); return result !is null ? new NSColor(result) : null; } public void setLeaf (bool flag) { OS.objc_msgSend(this.id, OS.sel_setLeaf_, flag); } }