mirror of https://github.com/buggins/dlangui.git
FileDialog path segment buttons
This commit is contained in:
parent
4cbf96784b
commit
1de90b5434
|
@ -123,16 +123,18 @@ Run Tetris game example
|
||||||
|
|
||||||
dub run dlangui:tetris --build=release
|
dub run dlangui:tetris --build=release
|
||||||
|
|
||||||
To develop using Visual-D, download sources for dlabgui and dependencies into some directory:
|
To develop using Visual-D or MonoD, download sources for dlabgui and dependencies into some directory:
|
||||||
|
|
||||||
git clone https://github.com/buggins/dlangui.git
|
git clone https://github.com/buggins/dlangui.git
|
||||||
git clone https://github.com/DerelictOrg/DerelictUtil.git
|
git clone https://github.com/DerelictOrg/DerelictUtil.git
|
||||||
git clone https://github.com/DerelictOrg/DerelictGL3.git
|
git clone https://github.com/DerelictOrg/DerelictGL3.git
|
||||||
git clone https://github.com/DerelictOrg/DerelictFI.git
|
|
||||||
git clone https://github.com/DerelictOrg/DerelictFT.git
|
git clone https://github.com/DerelictOrg/DerelictFT.git
|
||||||
git clone https://github.com/DerelictOrg/DerelictSDL2.git
|
git clone https://github.com/DerelictOrg/DerelictSDL2.git
|
||||||
|
git clone https://github.com/gecko0307/dlib.git
|
||||||
|
git clone https://github.com/Devisualization/image.git de_image
|
||||||
|
|
||||||
Then open .sln using Visual D.
|
|
||||||
|
Then open dlangui.sln using Visual D (or dlangui-monod.sln for MonoD)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -351,8 +351,8 @@ class FilePathPanelItem : HorizontalLayout {
|
||||||
|
|
||||||
class FilePathPanelButtons : WidgetGroup {
|
class FilePathPanelButtons : WidgetGroup {
|
||||||
protected string _path;
|
protected string _path;
|
||||||
this() {
|
this(string ID = null) {
|
||||||
super(null);
|
super(ID);
|
||||||
}
|
}
|
||||||
void init(string path) {
|
void init(string path) {
|
||||||
_path = path;
|
_path = path;
|
||||||
|
@ -447,9 +447,25 @@ class FilePathPanelButtons : WidgetGroup {
|
||||||
}
|
}
|
||||||
|
|
||||||
class FilePathPanel : FrameLayout {
|
class FilePathPanel : FrameLayout {
|
||||||
protected HorizontalLayout _segments;
|
static const ID_SEGMENTS = "SEGMENTS";
|
||||||
|
static const ID_EDITOR = "ED_PATH";
|
||||||
|
protected FilePathPanelButtons _segments;
|
||||||
protected EditLine _edPath;
|
protected EditLine _edPath;
|
||||||
|
protected string _path;
|
||||||
this(string ID = null) {
|
this(string ID = null) {
|
||||||
super(ID);
|
super(ID);
|
||||||
|
_segments = new FilePathPanelButtons(ID_SEGMENTS);
|
||||||
|
_edPath = new EditLine(ID_EDITOR);
|
||||||
|
addChild(_segments);
|
||||||
|
addChild(_edPath);
|
||||||
|
showChild(ID_SEGMENTS);
|
||||||
}
|
}
|
||||||
|
@property void path(string value) {
|
||||||
|
_segments.init(value);
|
||||||
|
_edPath.text = toUTF32(value);
|
||||||
|
_path = path;
|
||||||
|
}
|
||||||
|
@property string path() {
|
||||||
|
return _path;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue