mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-02 15:53:51 +00:00
Improve player frame context menu: name header, Leave Group when in group
This commit is contained in:
parent
c170216e1c
commit
347e958703
1 changed files with 10 additions and 2 deletions
|
|
@ -2082,12 +2082,20 @@ void GameScreen::renderPlayerFrame(game::GameHandler& gameHandler) {
|
||||||
gameHandler.setTarget(gameHandler.getPlayerGuid());
|
gameHandler.setTarget(gameHandler.getPlayerGuid());
|
||||||
}
|
}
|
||||||
if (ImGui::BeginPopupContextItem("PlayerSelfCtx")) {
|
if (ImGui::BeginPopupContextItem("PlayerSelfCtx")) {
|
||||||
if (ImGui::Selectable("Open Character")) {
|
ImGui::TextDisabled("%s", playerName.c_str());
|
||||||
|
ImGui::Separator();
|
||||||
|
if (ImGui::MenuItem("Open Character")) {
|
||||||
inventoryScreen.setCharacterOpen(true);
|
inventoryScreen.setCharacterOpen(true);
|
||||||
}
|
}
|
||||||
if (ImGui::Selectable("Toggle PvP")) {
|
if (ImGui::MenuItem("Toggle PvP")) {
|
||||||
gameHandler.togglePvp();
|
gameHandler.togglePvp();
|
||||||
}
|
}
|
||||||
|
if (gameHandler.isInGroup()) {
|
||||||
|
ImGui::Separator();
|
||||||
|
if (ImGui::MenuItem("Leave Group")) {
|
||||||
|
gameHandler.leaveGroup();
|
||||||
|
}
|
||||||
|
}
|
||||||
ImGui::EndPopup();
|
ImGui::EndPopup();
|
||||||
}
|
}
|
||||||
ImGui::PopStyleColor();
|
ImGui::PopStyleColor();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue