Παρουσίαση με Ετικέτες

Gotcha: MediaElement Source=null releases stream, SetSource(null) fails
12 Δεκεμβρίου 14 05:32 πμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
This is my contribution to: http://stackoverflow.com/questions/19294258/forcing-mediaelement-to-release-stream-after-playback/27436323 If you use MediaElement, make sure you don’t get bitten by this one: http://msdn.microsoft.com/en-us/library/cc626563(v=vs.95).aspx ArgumentNullException – The mediaStreamSource is null. … After calling this method, MediaElement.Source returns null. If this is called and MediaElement.Source is set, the last operation wins. If a MediaElement is removed from the UI tree […]
Δημοσίευση στην κατηγορία: , , , , , , , , , , , ,
Gotcha: MediaElement must be in visual tree for MediaOpened, MediaEnded to be fired
18 Νοεμβρίου 14 04:18 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
At ClipFlair’s AudioRecorderControl (used in Captions/Revoicing component of ClipFlair Studio), I use the following code to initialize a MediaElement to use for playback. After a long time a found out that if the MediaElement is not in the visual tree (for example defined in XAML, or defined in code and then added to the visual […]
Δημοσίευση στην κατηγορία: , , , , , , , , ,
Gotcha: MediaElement AutoPlay faster than doing Play at MediaOpened
18 Νοεμβρίου 14 02:27 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
Just added the following comment to: https://github.com/loarabia/ManagedMediaHelpers/issues/15 Managed Media Helpers contains the very useful Mp3MediaSource class for .NET / Silverlight / Windows Phone. Added compile-time SWITCHES and respective code to Silverlight demo code for PRELOAD (into memory stream) and AUTOPLAY (this was a bit tricky, need to call Play at MediaOpened event, not right after […]
Δημοσίευση στην κατηγορία: , , , , , , , , ,
Gotcha: System.IO.GetInvalidPathChars result not guaranteed
04 Απριλίου 14 12:54 πμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
at System.IO.Path.GetInvalidPathChars one reads: The array returned from this method is not guaranteed to contain the complete set of characters that are invalid in file and directory names note: can also call this method from non-trusted Silverlight app – not as Intellisense tooltip wrongly says in Visual Studio 2013 with Silverlight 5.1 I just found […]
Δημοσίευση στην κατηγορία: , , , , , , , , ,
Gotcha: OnLostMouseCapture always called by CaptureMouse at WPF
14 Μαρτίου 14 12:08 πμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
It seems that CaptureMouse is behaving differently in WPF and Silverlight, in that in the former one it immediately calls OnLostMouseCapture at a Visual, whereas in Silverlight it doesn’t get called if the element didn’t have the mouse capture already (btw, in Silverlight that method is at a UIElement – there is no Visual ancestor […]
Δημοσίευση στην κατηγορία: , , , , , , , , , , , , ,
Gotcha: var x = x() in Javascript gives “Object Expected” error
14 Ιουνίου 13 12:27 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
At ClipFlair Studio (a Silverlight app), I had some time ago implemented a confirmation warning upon user trying to close the webpage (when it was running inside the web browser), which then had stopped functioning. It seems at some refactoring I had added code like the following: var activityView = activityView(); and it was failing […]
Gotcha: Image component not loading remote URLs during debugging
18 Δεκεμβρίου 12 01:13 πμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
At ClipFlair’s Image component I use the following XAML to make it show an image from a URL that its ViewModel holds at a property named “Source”, of type Uri (URI = Uniform or Universal Resource Identifier in W3C parlance, something like a superset of the old classic URLs). <Image Name="imgContent"        HorizontalAlignment="Stretch" VerticalAlignment="Stretch"        [...]
Δημοσίευση στην κατηγορία: , , , , , , , , ,
Can’t step-through Silverlight file dialogs with Visual Studio debugger
02 Δεκεμβρίου 12 08:58 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
While stepping through “ShowDialog()” method of OpenFileDialog with Visual Studio 2010 debugger, at the Silverlight code pictured below (for loading a ClipFlair window’s stored options), I got a “Dialogs must be user-initiated” exception. Same behaviour will be shown with SaveFileDialog too, every time you try to step through the “ShowDialog()” method. This is because of [...]
Δημοσίευση στην κατηγορία: , , , , , , , , ,
Gotcha: Silverlight DependencyProperty metadata: 0d not 0 for double
09 Αυγούστου 12 11:38 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
Just came accross a runtime error message that troubled me a bit to resolve while adding Prezi-like content scaling functionality in ClipFlair‘s FloatingWindowHostZUI (ZUI = Zoomable User Interface) container. I had added the following: /// Identifies the <see cref="FloatingWindow.Scale" /> dependency property. /// </summary> /// <value> /// The identifier for the <see cref="FloatingWindow.Scale" /> dependency [...]
Δημοσίευση στην κατηγορία: , , , , , , , , , , ,
Gotcha: Silverlight’s Uri class constructor eats up part after last slash
22 Ιουλίου 12 10:54 μμ | Μπιρμπίλης Γεώργιος | 0 σχόλια   
Via trial and error, I recently found out that when creating a Uri combining another Uri and a suffix part (tried at Silverlight, but I guess it’s a .NET issue in general), it eats up the last part of the (first) Uri if it doesn’t end with "/". That is, if you combine http://test.com/a with [...]
Δημοσίευση στην κατηγορία: , , , , , , ,

Search

Go

Ιστορικό Δημοσιεύσεων

Συνδρομές