Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Pouliot <sebastien@ximian.com>2010-03-19 22:01:31 +0300
committerSebastien Pouliot <sebastien@ximian.com>2010-03-19 22:01:31 +0300
commit355a27b73dd51d786c42be36f03852383c001360 (patch)
tree92b63fa8f9f54ddd96c5ed8654013df39f26a50e /mcs/class/System/System.Timers
parentb1dfcf6b8b72754617374cb0609f027416cdb879 (diff)
In System.Timers:
2010-03-19 Sebastien Pouliot <sebastien@ximian.com> * Timer.cs: Removed old NET_2_0 defines and added some new MOONLIGHT defines (needed for the client stack) In System.Net: 2010-03-19 Sebastien Pouliot <sebastien@ximian.com> * AuthenticationManager.cs: Internal type for Moonlight. Add BasicClient, DigestClient, NtlmClient for NET_2_1 since this applies to both monotouch and moonlight (client stack). Removed unneeded NET_2_0 defines * CookieContainer.cs: For Moonlight it needs to be internal in System.dll and public in System.Net.dll. Removed unneeded NET_2_0 defines * HttpContinueDelegate.cs: Internal type for Moonlight. * HttpRequestCreator.cs: Remove a MOONLIGHT define * HttpStatusCode.cs: For Moonlight it needs to be internal in System.dll and public in System.Net.dll * HttpWebRequest.cs: Internal type for Moonlight. Change S.Config to NET_2_1 defines (applies to both monotouch and moonlight). Removed unneeded NET_2_0 and NET_1_1 defines * HttpWebResponse.cs: Internal type for Moonlight. Removed unneeded NET_2_0 defines * IAuthenticationModule.cs: Internal type for Moonlight. * ICertificatePolicy.cs: Internal type for Moonlight. * ICredentialPolicy.cs: Internal type for Moonlight. Removed unneeded NET_2_0 defines * IWebRequestCreate.cs: For Moonlight it needs to be internal in System.dll and public in System.Net.dll * ServicePoint.cs: Internal type for Moonlight. Change S.Config to NET_2_1 defines (applies to both monotouch and moonlight) * ServicePointManager.cs: Remove a MOONLIGHT define * WebException.cs: For Moonlight it needs to be internal in System.dll and public in System.Net.dll. Removed unneeded NET_2_0 defines * WebHeaderCollection.cs: Internal type for Moonlight. Removed unneeded NET_2_0 defines * WebRequest.cs: Internal type for Moonlight. Change S.Config to NET_2_1 defines (applies to both monotouch and moonlight) * WebResponse.cs: Internal type for Moonlight. Removed unneeded NET_2_0 defines In System.Net.Sockets: 2010-03-19 Sebastien Pouliot <sebastien@ximian.com> * Socket.cs: Remove some NET_2_0 defines (using) and add a few MOONLIGHT defines needed to reuse Socket in the client http stack * Socket_2_1.cs: Remove some MOONLIGHT defines * SocketAsyncEventArgs.cs: For Moonlight check policy if outside System.dll (the client stack use sockets with it's own web xdomain policy) In System: 2010-03-19 Sebastien Pouliot <sebastien@ximian.com> * Uri.cs: Remove some MOONLIGHT defines In .: 2010-03-19 Sebastien Pouliot <sebastien@ximian.com> * moonlight_*_System.dll.sources: Bring extra types so we can build a full, managed, internal HTTP stack to be reused for SL3+ * Makefile: Add a INSIDE_SYSTEM define when compiling System.dll to makes it possible to rebuild the same types in System.Net.dll svn path=/trunk/mcs/; revision=153916
Diffstat (limited to 'mcs/class/System/System.Timers')
-rw-r--r--mcs/class/System/System.Timers/ChangeLog5
-rw-r--r--mcs/class/System/System.Timers/Timer.cs21
2 files changed, 19 insertions, 7 deletions
diff --git a/mcs/class/System/System.Timers/ChangeLog b/mcs/class/System/System.Timers/ChangeLog
index 1ef812cbaa4..e417d1b4d09 100644
--- a/mcs/class/System/System.Timers/ChangeLog
+++ b/mcs/class/System/System.Timers/ChangeLog
@@ -1,3 +1,8 @@
+2010-03-19 Sebastien Pouliot <sebastien@ximian.com>
+
+ * Timer.cs: Removed old NET_2_0 defines and added some new
+ MOONLIGHT defines (needed for the client stack)
+
2009-09-29 Sebastien Pouliot <sebastien@ximian.com>
* Timer_2_1.cs: Removed. No longer needed by Moonlight
diff --git a/mcs/class/System/System.Timers/Timer.cs b/mcs/class/System/System.Timers/Timer.cs
index fc907a6a8d4..6126b9dcb65 100644
--- a/mcs/class/System/System.Timers/Timer.cs
+++ b/mcs/class/System/System.Timers/Timer.cs
@@ -35,10 +35,13 @@ using System.Threading;
namespace System.Timers
{
+#if MOONLIGHT
+ internal class Timer {
+#else
[DefaultEventAttribute("Elapsed")]
[DefaultProperty("Interval")]
- public class Timer : Component, ISupportInitialize
- {
+ public class Timer : Component, ISupportInitialize {
+#endif
double interval;
bool autoReset;
System.Threading.Timer timer;
@@ -55,11 +58,9 @@ namespace System.Timers
public Timer (double interval)
{
-#if NET_2_0
// MSBUG: https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=296761
if (interval > 0x7FFFFFFF)
throw new ArgumentException ("Invalid value: " + interval, "interval");
-#endif
autoReset = true;
Interval = interval;
@@ -119,18 +120,17 @@ namespace System.Timers
}
}
+#if !MOONLIGHT
public override ISite Site
{
get { return base.Site; }
set { base.Site = value; }
}
-
+#endif
[DefaultValue(null)]
[TimersDescriptionAttribute("The object used to marshal the event handler calls issued " +
"when an interval has elapsed.")]
-#if NET_2_0
[Browsable (false)]
-#endif
public ISynchronizeInvoke SynchronizingObject
{
get { return so; }
@@ -162,11 +162,18 @@ namespace System.Timers
Enabled = false;
}
+#if MOONLIGHT
+ protected void Dispose (bool disposing)
+ {
+ Close ();
+ }
+#else
protected override void Dispose (bool disposing)
{
Close ();
base.Dispose (disposing);
}
+#endif
static void Callback (object state)
{