[PATCH 1/3] mstask: Make each source file self-contained.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[PATCH 1/3] mstask: Make each source file self-contained.

Dmitry Timoshkov
Signed-off-by: Dmitry Timoshkov <[hidden email]>
---
 dlls/mstask/Makefile.in      |  2 +-
 dlls/mstask/factory.c        |  8 ++++++++
 dlls/mstask/mstask_local.idl |  1 -
 dlls/mstask/mstask_main.c    | 11 +++++++----
 dlls/mstask/mstask_private.h | 10 ----------
 dlls/mstask/task.c           |  8 ++++++++
 dlls/mstask/task_scheduler.c | 14 +++++++++++---
 dlls/mstask/task_trigger.c   |  7 +++++++
 8 files changed, 42 insertions(+), 19 deletions(-)

diff --git a/dlls/mstask/Makefile.in b/dlls/mstask/Makefile.in
index 55ab76dbbe..72a6db3eb7 100644
--- a/dlls/mstask/Makefile.in
+++ b/dlls/mstask/Makefile.in
@@ -1,5 +1,5 @@
 MODULE    = mstask.dll
-IMPORTS   = uuid ole32
+IMPORTS   = ole32
 
 C_SRCS = \
  factory.c \
diff --git a/dlls/mstask/factory.c b/dlls/mstask/factory.c
index f85a5f9c11..97a5113868 100644
--- a/dlls/mstask/factory.c
+++ b/dlls/mstask/factory.c
@@ -16,6 +16,14 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
+#include <stdarg.h>
+
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
+#include "objbase.h"
+#include "mstask.h"
 #include "mstask_private.h"
 #include "wine/debug.h"
 
diff --git a/dlls/mstask/mstask_local.idl b/dlls/mstask/mstask_local.idl
index 98e060c468..bf49728e66 100644
--- a/dlls/mstask/mstask_local.idl
+++ b/dlls/mstask/mstask_local.idl
@@ -16,7 +16,6 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#pragma makedep ident
 #pragma makedep register
 
 #include "mstask.idl"
diff --git a/dlls/mstask/mstask_main.c b/dlls/mstask/mstask_main.c
index aa6693d1e8..bb19b89da2 100644
--- a/dlls/mstask/mstask_main.c
+++ b/dlls/mstask/mstask_main.c
@@ -16,15 +16,18 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#include <stdio.h>
+#include <stdarg.h>
 
-#include "mstask_private.h"
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
 #include "objbase.h"
 #include "rpcproxy.h"
-
+#include "mstask.h"
+#include "mstask_private.h"
 #include "wine/debug.h"
 
-
 WINE_DEFAULT_DEBUG_CHANNEL(mstask);
 
 static HINSTANCE hInst;
diff --git a/dlls/mstask/mstask_private.h b/dlls/mstask/mstask_private.h
index 17c20fee43..9180e4a51f 100644
--- a/dlls/mstask/mstask_private.h
+++ b/dlls/mstask/mstask_private.h
@@ -19,16 +19,6 @@
 #ifndef __MSTASK_PRIVATE_H__
 #define __MSTASK_PRIVATE_H__
 
-#include <stdarg.h>
-
-#define COBJMACROS
-
-#include "windef.h"
-#include "winbase.h"
-#include "winuser.h"
-#include "ole2.h"
-#include "mstask.h"
-
 extern LONG dll_ref DECLSPEC_HIDDEN;
 
 typedef struct ClassFactoryImpl ClassFactoryImpl;
diff --git a/dlls/mstask/task.c b/dlls/mstask/task.c
index 97ae8b7b67..872e445b5e 100644
--- a/dlls/mstask/task.c
+++ b/dlls/mstask/task.c
@@ -16,6 +16,14 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
+#include <stdarg.h>
+
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
+#include "objbase.h"
+#include "mstask.h"
 #include "mstask_private.h"
 #include "wine/debug.h"
 
diff --git a/dlls/mstask/task_scheduler.c b/dlls/mstask/task_scheduler.c
index 1f367edb3d..1c2d227ddb 100644
--- a/dlls/mstask/task_scheduler.c
+++ b/dlls/mstask/task_scheduler.c
@@ -16,7 +16,15 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#include "corerror.h"
+#include <stdarg.h>
+
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
+#include "initguid.h"
+#include "objbase.h"
+#include "mstask.h"
 #include "mstask_private.h"
 #include "wine/debug.h"
 
@@ -268,8 +276,8 @@ static HRESULT WINAPI MSTASK_ITaskScheduler_Activate(
 {
     TRACE("%p, %s, %s, %p: stub\n", iface, debugstr_w(pwszName),
             debugstr_guid(riid), ppunk);
-    FIXME("Partial stub always returning COR_E_FILENOTFOUND\n");
-    return COR_E_FILENOTFOUND;
+    FIXME("Partial stub always returning ERROR_FILE_NOT_FOUND\n");
+    return HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND);
 }
 
 static HRESULT WINAPI MSTASK_ITaskScheduler_Delete(
diff --git a/dlls/mstask/task_trigger.c b/dlls/mstask/task_trigger.c
index 448cf08708..9475e5608a 100644
--- a/dlls/mstask/task_trigger.c
+++ b/dlls/mstask/task_trigger.c
@@ -17,7 +17,14 @@
  */
 
 #include <stdarg.h>
+
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
+#include "objbase.h"
 #include "winternl.h"
+#include "mstask.h"
 #include "mstask_private.h"
 #include "wine/debug.h"
 
--
2.16.2