Skip to content

Commit 47ba868

Browse files
Merge pull request #41 from rocksdanister/dev-build
Dev build
2 parents 2232b4d + 6cc3f42 commit 47ba868

13 files changed

+392
-373
lines changed

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -97,17 +97,17 @@ Help translate lively to other languages: <a href="https://github.com/rocksdanis
9797

9898
**_I'm not officially affiliated with Unity technologies, godot, shadertoy;_**
9999
## Download
100-
##### Latest version: v0.9.5.0 (Windows 10, 8.1)[What's new?](https://github.com/rocksdanister/lively/releases/tag/v0.9.5.0)
100+
##### Latest version: v0.9.5.1 (Windows 10, 8.1)[What's new?](https://github.com/rocksdanister/lively/releases/tag/v0.9.5.1)
101101
- [`Download Lively Installer`][direct-full-win32]
102102
_102MB, Web wallpaper support & some sample wallpapers included._
103103
- [`Download Lively Portable`][direct-full-portable-win32]
104104
_111MB, (No Installation) Web wallpaper support & some sample wallpapers included._
105105

106106
**Portable build: Latest Visual C++ Redistributable is required: [vc_redist.x86.exe](https://aka.ms/vs/16/release/vc_redist.x86.exe)**
107107

108-
[direct-full-win32]: https://github.com/rocksdanister/lively/releases/download/v0.9.5.0/lively_setup_x86_full_v0950.exe
108+
[direct-full-win32]: https://github.com/rocksdanister/lively/releases/download/v0.9.5.1/lively_setup_x86_full_v0951.exe
109109

110-
[direct-full-portable-win32]: https://github.com/rocksdanister/lively/releases/download/v0.9.5.0/lively_portable_x86_full_v0950.zip
110+
[direct-full-portable-win32]: https://github.com/rocksdanister/lively/releases/download/v0.9.5.1/lively_portable_x86_full_v0951.zip
111111

112112
**Installer will give Smartscreen warning, [discussion.](https://github.com/rocksdanister/lively/issues/9)**
113113

src/lively setup/Inno.iss

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
33

44
#define MyAppName "Lively Wallpaper"
5-
#define MyAppVersion "0.9.0.0"
5+
#define MyAppVersion "0.9.5.1"
66
#define MyAppPublisher "rocksdanister"
77
#define MyAppURL "https://github.com/rocksdanister/lively"
88
#define MyAppExeName "livelywpf.exe"

src/livelywpf/livelywpf/Properties/AssemblyInfo.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,5 @@
5151
// You can specify all the values or you can default the Build and Revision Numbers
5252
// by using the '*' as shown below:
5353
// [assembly: AssemblyVersion("1.0.*")]
54-
[assembly: AssemblyVersion("0.9.5.0")]
54+
[assembly: AssemblyVersion("0.9.5.1")]
5555
[assembly: AssemblyFileVersion("1.0.0.0")]

src/livelywpf/livelywpf/Properties/Resources.ru.resx

+232-237
Large diffs are not rendered by default.

src/livelywpf/livelywpf/docs/changelog.rtf

+95-49
Large diffs are not rendered by default.

src/livelywpf/livelywpf/livelywpf.csproj

-7
Original file line numberDiff line numberDiff line change
@@ -351,9 +351,6 @@
351351
<Compile Include="wp_lib\RawInputDX.xaml.cs">
352352
<DependentUpon>RawInputDX.xaml</DependentUpon>
353353
</Compile>
354-
<Compile Include="wp_windows\LivelywpHolder.xaml.cs">
355-
<DependentUpon>LivelywpHolder.xaml</DependentUpon>
356-
</Compile>
357354
<Compile Include="preview\PreviewWallpaper.xaml.cs">
358355
<DependentUpon>PreviewWallpaper.xaml</DependentUpon>
359356
</Compile>
@@ -431,10 +428,6 @@
431428
<SubType>Designer</SubType>
432429
<Generator>MSBuild:Compile</Generator>
433430
</Page>
434-
<Page Include="wp_windows\LivelywpHolder.xaml">
435-
<SubType>Designer</SubType>
436-
<Generator>MSBuild:Compile</Generator>
437-
</Page>
438431
<Page Include="preview\PreviewWallpaper.xaml">
439432
<SubType>Designer</SubType>
440433
<Generator>MSBuild:Compile</Generator>

src/livelywpf/livelywpf/wp_lib/RawInputDX.xaml.cs

+26-21
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ private void Window_SourceInitialized(object sender, EventArgs e)
4040
var windowInteropHelper = new WindowInteropHelper(this);
4141
var hwnd = windowInteropHelper.Handle;
4242

43-
//ExInputSink flag makes it work even when not in foreground, similar to global hook.. but asynchronous!
43+
//ExInputSink flag makes it work even when not in foreground, similar to global hook.. but asynchronous, no complications & no AV false detection!
4444
RawInputDevice.RegisterDevice(HidUsageAndPage.Mouse,
4545
RawInputDeviceFlags.ExInputSink, hwnd);
4646

@@ -215,30 +215,35 @@ private static void ForwardMessage(int x, int y, int msg, IntPtr wParam)
215215
/// <returns>Localised cursor value</returns>
216216
private static Point CalculateMousePos(int x, int y, Screen display)
217217
{
218-
if(!MainWindow.Multiscreen || SaveData.config.WallpaperArrangement == SaveData.WallpaperArrangement.span)
218+
if (MainWindow.Multiscreen)
219219
{
220-
return new Point(x, y);
221-
}
222-
223-
if (x < 0)
224-
{
225-
x = SystemInformation.VirtualScreen.Width + x - Screen.PrimaryScreen.Bounds.Width;
226-
}
227-
else
228-
{
229-
x -= Math.Abs(display.Bounds.X);
230-
}
220+
if (SaveData.config.WallpaperArrangement == SaveData.WallpaperArrangement.span)
221+
{
222+
x -= SystemInformation.VirtualScreen.Location.X;
223+
y -= SystemInformation.VirtualScreen.Location.Y;
224+
}
225+
else //per-display or duplicate mode.
226+
{
227+
if (x < 0)
228+
{
229+
x = SystemInformation.VirtualScreen.Width + x - Screen.PrimaryScreen.Bounds.Width;
230+
}
231+
else
232+
{
233+
x -= Math.Abs(display.Bounds.X);
234+
}
231235

232-
if (y < 0)
233-
{
234-
y = SystemInformation.VirtualScreen.Height + y - Screen.PrimaryScreen.Bounds.Height;
235-
}
236-
else
237-
{
238-
y -= Math.Abs(display.Bounds.Y);
236+
if (y < 0)
237+
{
238+
y = SystemInformation.VirtualScreen.Height + y - Screen.PrimaryScreen.Bounds.Height;
239+
}
240+
else
241+
{
242+
y -= Math.Abs(display.Bounds.Y);
243+
}
244+
}
239245
}
240246
return new Point(x, y);
241247
}
242-
243248
}
244249
}

src/livelywpf/livelywpf/wp_lib/SetupDesktop.cs

+13-11
Original file line numberDiff line numberDiff line change
@@ -396,8 +396,7 @@ public static async void SetWallpaper(SaveData.WallpaperLayout layout, bool show
396396
extVidPlayers.Add(new ExtVidPlayers(handle, layout.DeviceName, proc, WallpaperType.video, 0));
397397

398398
BorderlessWinStyle(handle);
399-
RemoveAppFromTaskbar(handle);
400-
//AddWallpaper(handle, layout.DeviceName);
399+
RemoveWindowFromTaskbar(handle);
401400
SaveData.runningPrograms.Add(new SaveData.RunningProgram { ProcessName = proc.ProcessName, Pid = proc.Id });
402401
SaveData.SaveRunningPrograms();
403402

@@ -514,9 +513,7 @@ public static async void SetWallpaper(SaveData.WallpaperLayout layout, bool show
514513
}
515514

516515
extPrograms.Add(new ExtProgram(handle, layout.DeviceName, proc, layout.Type, 0));
517-
//removing from taskbar.
518-
//StaticPinvoke.SetWindowLongPtr(new HandleRef(null,handle), (-20),(IntPtr)StaticPinvoke.WS_EX_TOOLWINDOW);
519-
RemoveAppFromTaskbar(handle);
516+
RemoveWindowFromTaskbar(handle);
520517

521518
AddWallpaper(handle, layout, showPreviewWindow);
522519

@@ -624,7 +621,7 @@ public static async void SetWallpaper(SaveData.WallpaperLayout layout, bool show
624621
extPrograms.Add(new ExtProgram(handle, layout.DeviceName, proc, layout.Type, 0));
625622

626623
BorderlessWinStyle(handle);
627-
RemoveAppFromTaskbar(handle);
624+
RemoveWindowFromTaskbar(handle);
628625

629626
AddWallpaper(handle, layout, showPreviewWindow);
630627

@@ -756,7 +753,7 @@ public static async void SetWallpaper(SaveData.WallpaperLayout layout, bool show
756753

757754
extPrograms.Add(new ExtProgram(handle, layout.DeviceName, proc, layout.Type, 0));
758755
BorderlessWinStyle(handle);
759-
RemoveAppFromTaskbar(handle);
756+
RemoveWindowFromTaskbar(handle);
760757

761758
AddWallpaper(handle, layout, showPreviewWindow);
762759

@@ -815,8 +812,8 @@ public static async void SetWallpaper(SaveData.WallpaperLayout layout, bool show
815812
return;
816813
}
817814

818-
//BorderlessWinStyle(handle);
819-
RemoveAppFromTaskbar(handle);
815+
BorderlessWinStyle(handle);
816+
RemoveWindowFromTaskbar(handle);
820817

821818
AddWallpaper(handle, layout, showPreviewWindow);
822819
//StaticPinvoke.ShowWindow(handle, 3); //maximise
@@ -2610,9 +2607,14 @@ public static void InitializeTimer()
26102607
}
26112608
}
26122609

2613-
private static void RemoveAppFromTaskbar(IntPtr handle)
2610+
public static void RemoveWindowFromTaskbar(IntPtr handle)
26142611
{
2615-
NativeMethods.SetWindowLongPtr(new HandleRef(null, handle), (int)NativeMethods.GWL.GWL_EXSTYLE, (IntPtr)NativeMethods.WindowStyles.WS_EX_NOACTIVATE);
2612+
var styleNewWindowExtended =
2613+
(Int64)NativeMethods.WindowStyles.WS_EX_NOACTIVATE
2614+
| (Int64)NativeMethods.WindowStyles.WS_EX_TOOLWINDOW;
2615+
2616+
// update window styles
2617+
NativeMethods.SetWindowLongPtr(new HandleRef(null, handle), (-20), (IntPtr)styleNewWindowExtended);
26162618
}
26172619

26182620
/// <summary>

src/livelywpf/livelywpf/wp_windows/GifWindow.xaml.cs

+7
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public partial class GifWindow : Window
2727
public GifWindow(string path)
2828
{
2929
InitializeComponent();
30+
this.Loaded += GifWindow_Loaded;
3031

3132
gifImg.Stretch = SaveData.config.GifScaler;
3233
AnimationBehavior.AddErrorHandler(gifImg, ErrorEvent);
@@ -35,6 +36,12 @@ public GifWindow(string path)
3536
AnimationBehavior.SetRepeatBehavior(gifImg, System.Windows.Media.Animation.RepeatBehavior.Forever);
3637
}
3738

39+
private void GifWindow_Loaded(object sender, RoutedEventArgs e)
40+
{
41+
//ShowInTaskbar = false :- causing issue with windows10 Taskview.
42+
SetupDesktop.RemoveWindowFromTaskbar(new WindowInteropHelper(this).Handle);
43+
}
44+
3845
private void ErrorEvent(object s, AnimationErrorEventArgs e)
3946
{
4047
Logger.Error("GIF:" + e.ToString());

src/livelywpf/livelywpf/wp_windows/LivelywpHolder.xaml

-16
This file was deleted.

src/livelywpf/livelywpf/wp_windows/LivelywpHolder.xaml.cs

-27
This file was deleted.

src/livelywpf/livelywpf/wp_windows/MediaPlayer.xaml.cs

+7
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ public partial class MediaPlayer : Window
2929
public MediaPlayer(string path, int playSpeed)
3030
{
3131
InitializeComponent();
32+
this.Loaded += MediaPlayer_Loaded;
3233

3334
mePlayer.LoadedBehavior = MediaState.Manual;
3435
mePlayer.Source = new Uri(path);
@@ -46,6 +47,12 @@ public MediaPlayer(string path, int playSpeed)
4647
mePlayer.Play();
4748
}
4849

50+
private void MediaPlayer_Loaded(object sender, RoutedEventArgs e)
51+
{
52+
//ShowInTaskbar = false :- causing issue with windows10 Taskview.
53+
SetupDesktop.RemoveWindowFromTaskbar(new WindowInteropHelper(this).Handle);
54+
}
55+
4956
private void MePlayer_MediaOpened(object sender, RoutedEventArgs e)
5057
{
5158

src/livelywpf/livelywpf/wp_windows/Mediakit.xaml.cs

+7
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ public partial class Mediakit : Window
2929
public Mediakit(string path, int playSpeed)
3030
{
3131
InitializeComponent();
32+
this.Loaded += Mediakit_Loaded;
3233

3334
mePlayer.LoadedBehavior = WPFMediaKit.DirectShow.MediaPlayers.MediaState.Manual;
3435
mePlayer.Source = new Uri(path);
@@ -47,6 +48,12 @@ public Mediakit(string path, int playSpeed)
4748
mePlayer.Play();
4849
}
4950

51+
private void Mediakit_Loaded(object sender, RoutedEventArgs e)
52+
{
53+
//ShowInTaskbar = false :- causing issue with windows10 Taskview.
54+
SetupDesktop.RemoveWindowFromTaskbar(new WindowInteropHelper(this).Handle);
55+
}
56+
5057
private void MePlayer_MediaOpened(object sender, RoutedEventArgs e)
5158
{
5259

0 commit comments

Comments
 (0)