Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bbbee53 commit 3ed2d25Copy full SHA for 3ed2d25
1 file changed
src/api/menuitem/menuitem_gtk.cc
@@ -80,8 +80,9 @@ void MenuItem::SetLabel(const std::string& label) {
80
}
81
82
void MenuItem::SetIcon(const std::string& icon) {
83
- if (icon.empty())
+ if (icon.empty()) {
84
gtk_image_menu_item_set_image(GTK_IMAGE_MENU_ITEM(menu_item_), NULL);
85
+ }
86
else {
87
gtk_image_menu_item_set_image(GTK_IMAGE_MENU_ITEM(menu_item_),
88
gtk_image_new_from_file(icon.c_str()));
0 commit comments