'Return the following boolean flags:
newconsole - the plugin should execute in a new console
waitmode   - Execution should wait for the plugin to finish
executing'

def get_runflags(self, mode, interactive, scripted):

    if interactive:
        if (not mode):
            mode = self.getConsoleMode()
    else:
        mode = util.CONSOLE_REUSE
    if (mode == util.CONSOLE_REUSE):
        newconsole = False
    else:
        newconsole = True
    waitmode = True
    if (interactive and (not scripted) and newconsole):
        waitmode = False
    return (waitmode, newconsole)
