Contextually change the button from workflow to credentials based on tab selection

Here is the current problem. Context is not understood by the top right button

Ideally this button is contextually aware of tab selections.
As a user I dont want to have to press the drop down on the button when I am already on the credentials tab… as its too many clicks.