mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2025-01-22 17:41:05 +00:00
2004-02-12 Zoltan Varga <vargaz@freemail.hu>
* glib/time_t_CustomMarshaler.cs: Update after custom marshaling changes. svn path=/trunk/gtk-sharp/; revision=23018
This commit is contained in:
parent
f52a27bf79
commit
d39ef22678
|
@ -1,3 +1,8 @@
|
|||
2004-02-12 Zoltan Varga <vargaz@freemail.hu>
|
||||
|
||||
* glib/time_t_CustomMarshaler.cs: Update after custom marshaling
|
||||
changes.
|
||||
|
||||
2004-02-11 Mike Kestner <mkestner@ximian.com>
|
||||
|
||||
* gtk/Gtk.metadata : hide the GSList API
|
||||
|
|
|
@ -53,15 +53,15 @@ namespace GLib {
|
|||
|
||||
public object MarshalNativeToManaged (IntPtr data)
|
||||
{
|
||||
int secs;
|
||||
long secs;
|
||||
if (GetNativeDataSize () == 4)
|
||||
secs = Marshal.ReadInt32 (data);
|
||||
secs = (int)data;
|
||||
else if (GetNativeDataSize () == 8)
|
||||
secs = (int) Marshal.ReadInt64 (data);
|
||||
secs = (long)data;
|
||||
else
|
||||
throw new Exception ("Unexpected native size for time_t.");
|
||||
|
||||
TimeSpan span = new TimeSpan (secs - utc_offset);
|
||||
TimeSpan span = new TimeSpan ((int)secs - utc_offset);
|
||||
return local_epoch.Add (span);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue