Signed-off-by: Gabriel Ivăncescu gabrielopcode@gmail.com ---
These helpers will be needed by more methods and other helpers (such as the next patch) so it's better to place them at the top and avoid pointless forward declarations.
dlls/msscript.ocx/msscript.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/dlls/msscript.ocx/msscript.c b/dlls/msscript.ocx/msscript.c index 816a99d..9cb8282 100644 --- a/dlls/msscript.ocx/msscript.c +++ b/dlls/msscript.ocx/msscript.c @@ -200,6 +200,16 @@ static struct named_item *host_get_named_item(ScriptHost *host, const WCHAR *nam return NULL; }
+static HRESULT set_script_state(ScriptHost *host, SCRIPTSTATE state) +{ + HRESULT hr; + + hr = IActiveScript_SetScriptState(host->script, state); + if (SUCCEEDED(hr)) + host->script_state = state; + return hr; +} + static inline ScriptControl *impl_from_IScriptControl(IScriptControl *iface) { return CONTAINING_RECORD(iface, ScriptControl, IScriptControl_iface); @@ -954,16 +964,6 @@ static HRESULT WINAPI ScriptControl_AddObject(IScriptControl *iface, BSTR name, return hr; }
-static HRESULT set_script_state(ScriptHost *host, SCRIPTSTATE state) -{ - HRESULT hr; - - hr = IActiveScript_SetScriptState(host->script, state); - if (SUCCEEDED(hr)) - host->script_state = state; - return hr; -} - static HRESULT WINAPI ScriptControl_Reset(IScriptControl *iface) { ScriptControl *This = impl_from_IScriptControl(iface);