2019-03-08 06:55:43 -08:00
|
|
|
enum @beta Efl.Ui.Alert_Popup_Button {
|
2017-08-22 23:50:18 -07:00
|
|
|
[[Defines the type of the alert button.]]
|
|
|
|
positive = 0, [[Button having positive meaning. e.g. "Yes"]]
|
|
|
|
negative, [[Button having negative meaning. e.g. "No"]]
|
|
|
|
user [[Button having user-defined meaning. e.g. "Cancel"]]
|
|
|
|
}
|
|
|
|
|
2019-03-08 06:55:43 -08:00
|
|
|
struct @beta Efl.Ui.Alert_Popup_Button_Clicked_Event {
|
2019-09-10 08:08:44 -07:00
|
|
|
[[Information for @[Efl.Ui.Alert_Popup.button,clicked] event.]]
|
2018-11-16 02:11:50 -08:00
|
|
|
button_type: Efl.Ui.Alert_Popup_Button; [[Clicked button type]]
|
2017-10-24 06:30:49 -07:00
|
|
|
}
|
|
|
|
|
2019-02-14 08:37:02 -08:00
|
|
|
class @beta Efl.Ui.Alert_Popup extends Efl.Ui.Popup
|
2017-08-22 23:50:18 -07:00
|
|
|
{
|
2019-09-10 08:08:44 -07:00
|
|
|
[[A variant of @Efl.Ui.Popup which uses a layout containing a content object and
|
|
|
|
a variable number of buttons (up to 3 total).
|
|
|
|
|
|
|
|
An Alert_Popup is a popup which can be used when an application requires user interaction. It provides
|
|
|
|
functionality for easily creating button objects on the popup and passing information about
|
|
|
|
which button has been pressed to the button event callback.
|
|
|
|
]]
|
2017-08-22 23:50:18 -07:00
|
|
|
methods {
|
|
|
|
@property button {
|
2019-09-10 08:08:44 -07:00
|
|
|
[[This property changes the text and icon for the specified button object.
|
|
|
|
|
|
|
|
When set, the Alert_Popup will create a button for the specified type if it does not yet
|
|
|
|
exist. The button's content and text will be set using the passed values.
|
|
|
|
|
|
|
|
Exactly one button may exist for each @Efl.Ui.Alert_Popup_Button type. Repeated calls to
|
|
|
|
set values for the same button type will overwrite previous values.
|
|
|
|
|
|
|
|
By default, no buttons are created.
|
|
|
|
]]
|
2017-08-22 23:50:18 -07:00
|
|
|
set {
|
|
|
|
}
|
|
|
|
keys {
|
2019-09-10 08:08:44 -07:00
|
|
|
type: Efl.Ui.Alert_Popup_Button; [[Alert_Popup button type]]
|
2017-08-22 23:50:18 -07:00
|
|
|
}
|
|
|
|
values {
|
2019-09-10 08:08:44 -07:00
|
|
|
text: string; [[Text of the specified button type.]]
|
|
|
|
icon: Efl.Canvas.Object; [[Visual to use as an icon for the specified button type.]]
|
2017-08-22 23:50:18 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
implements {
|
2017-10-24 05:29:15 -07:00
|
|
|
Efl.Object.constructor;
|
|
|
|
Efl.Object.destructor;
|
2018-05-03 16:34:17 -07:00
|
|
|
Efl.Part.part_get;
|
2017-08-22 23:50:18 -07:00
|
|
|
}
|
|
|
|
events {
|
2019-09-10 08:08:44 -07:00
|
|
|
button,clicked: Efl.Ui.Alert_Popup_Button_Clicked_Event; [[Called when an Alert_Popup button was clicked.]]
|
2017-08-22 23:50:18 -07:00
|
|
|
}
|
|
|
|
}
|