Watashi o yūwaku suru
Watashi o yūwaku suru
Explore posts from servers
CC#
Created by Watashi o yūwaku suru on 5/6/2024 in #help
Animating both values at the same time
Is it possible to implement resize window of two values “height”, “width” in one moment? Without waiting for the action of one and after the other? :PaimonNomming:
private void ResizeWindow(double width, double height)
{
Duration duration = TimeSpan.FromSeconds(2);

DoubleAnimation widthAnimation = new DoubleAnimation();
widthAnimation.To = width;
widthAnimation.Duration = duration;

DoubleAnimation heightAnimation = new DoubleAnimation();
heightAnimation.To = height;
heightAnimation.Duration = duration;

Storyboard storyboard = new Storyboard();
storyboard.Children.Add(widthAnimation);
storyboard.Children.Add(heightAnimation);
Storyboard.SetTarget(widthAnimation, this);
Storyboard.SetTarget(heightAnimation, this);
Storyboard.SetTargetProperty(widthAnimation, new PropertyPath(Window.WidthProperty));
Storyboard.SetTargetProperty(heightAnimation, new PropertyPath(Window.HeightProperty));

storyboard.Begin();
}

private void Button_Click(object sender, RoutedEventArgs e)
{
ResizeWindow(640, 360);
}
private void ResizeWindow(double width, double height)
{
Duration duration = TimeSpan.FromSeconds(2);

DoubleAnimation widthAnimation = new DoubleAnimation();
widthAnimation.To = width;
widthAnimation.Duration = duration;

DoubleAnimation heightAnimation = new DoubleAnimation();
heightAnimation.To = height;
heightAnimation.Duration = duration;

Storyboard storyboard = new Storyboard();
storyboard.Children.Add(widthAnimation);
storyboard.Children.Add(heightAnimation);
Storyboard.SetTarget(widthAnimation, this);
Storyboard.SetTarget(heightAnimation, this);
Storyboard.SetTargetProperty(widthAnimation, new PropertyPath(Window.WidthProperty));
Storyboard.SetTargetProperty(heightAnimation, new PropertyPath(Window.HeightProperty));

storyboard.Begin();
}

private void Button_Click(object sender, RoutedEventArgs e)
{
ResizeWindow(640, 360);
}
4 replies
CDCloudflare Developers
Created by Watashi o yūwaku suru on 4/10/2024 in #pages-help
Deploying Next.js site
{
"name": "aksueikava",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
{
"name": "aksueikava",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
After building ouput I have .next/static, directly I point to cloudflare pages
Build command: pnpm run build
Build output directory : /.next/static
Root directory: /
Build command: pnpm run build
Build output directory : /.next/static
Root directory: /
All successful, but in one browser the old site, on other browsers - nothing loads
1 replies