示例#1
0
 private void removeBytesBtn_Click(object sender, EventArgs e)
 {
     if (Program.IsPathValid(Program.currentDir))
     {
         OtherUtils.RemoveBytesDir(removeBytesAmount.GetInt());
     }
 }
示例#2
0
 private void zeropadBtn_Click(object sender, EventArgs e)
 {
     if (Program.IsPathValid(Program.currentDir))
     {
         OtherUtils.AddZeroPaddingDir(zeroPaddingCombox.GetInt());
     }
 }
示例#3
0
 private void printInfoBtn_Click(object sender, EventArgs e)
 {
     if (Program.IsPathValid(Program.currentDir))
     {
         OtherUtils.PrintImageInfoDir();
     }
 }
示例#4
0
 private void delMissingTestBtn_Click(object sender, EventArgs e)
 {
     if (Program.IsPathValid(Program.currentDir))
     {
         OtherUtils.DelMissing(checkDirTbox.Text.Trim(), true);
     }
 }
示例#5
0
 private void renameCounterBtn_Click(object sender, EventArgs e)
 {
     if (Program.IsPathValid(Program.currentDir))
     {
         OtherUtils.RenameCounterDir(renameCounterMode.SelectedIndex, renameCounterPadding.SelectedIndex == 1, renameCounterStartAt.GetInt());
     }
 }
示例#6
0
 private void groupNormalsBtn_Click(object sender, EventArgs e)
 {
     if (!Program.IsPathValid(Program.currentDir))
     {
         return;
     }
     OtherUtils.GroupNormalsWithTex(normalSuffixCombox.Text, diffSuffixCombox.Text, lowercaseCbox.Checked);
 }
示例#7
0
 private void delFilesNotMatchingExtBtn_Click(object sender, EventArgs e)
 {
     if (!Program.IsPathValid(Program.currentDir))
     {
         return;
     }
     OtherUtils.DelNotMatchingWildcard(recursiveCbox.Checked);
 }
示例#8
0
 private void replaceBtn_Click(object sender, EventArgs e)
 {
     if (String.IsNullOrWhiteSpace(replaceInputTbox.Text))
     {
         Program.Print("Can't replace an empty string!");
     }
     else
     {
         OtherUtils.ReplaceInFilenamesDir(replaceInputTbox.Text, replaceOutputTbox.Text);
     }
 }
示例#9
0
        private void delSmallImagesBtn_Click(object sender, EventArgs e)
        {
            if (!Program.IsPathValid(Program.currentDir))
            {
                return;
            }
            int minSize = int.Parse(delSmallImagesSizeCombox.Text);

            ImageSizeFilterUtils.SizeMode sizeMode = ImageSizeFilterUtils.SizeMode.Height;
            if (delImgsMode.SelectedIndex == 1)
            {
                sizeMode = ImageSizeFilterUtils.SizeMode.Width;
            }
            if (delImgsMode.SelectedIndex == 2)
            {
                sizeMode = ImageSizeFilterUtils.SizeMode.LongerSide;
            }
            if (delImgsMode.SelectedIndex == 3)
            {
                sizeMode = ImageSizeFilterUtils.SizeMode.ShorterSide;
            }
            if (delImgsMode.SelectedIndex == 4)
            {
                sizeMode = ImageSizeFilterUtils.SizeMode.EitherSide;
            }
            if (delImgsMode.SelectedIndex == 5)
            {
                sizeMode = ImageSizeFilterUtils.SizeMode.BothSides;
            }
            ImageSizeFilterUtils.Operator op = ImageSizeFilterUtils.Operator.IsNot;
            if (delImgOperator.SelectedIndex == 1)
            {
                op = ImageSizeFilterUtils.Operator.Is;
            }
            if (delImgOperator.SelectedIndex == 2)
            {
                op = ImageSizeFilterUtils.Operator.IsSmaller;
            }
            if (delImgOperator.SelectedIndex == 3)
            {
                op = ImageSizeFilterUtils.Operator.IsBigger;
            }
            if (delImgOperator.SelectedIndex == 4)
            {
                op = ImageSizeFilterUtils.Operator.Divisible;
            }
            if (delImgOperator.SelectedIndex == 5)
            {
                op = ImageSizeFilterUtils.Operator.NotDivisible;
            }
            OtherUtils.DelSmallImgsDir(minSize, sizeMode, op);
        }
示例#10
0
        private void button2_Click(object sender, EventArgs e)
        {
            bool suffix = suffixPrefixCombox.SelectedIndex != 0;

            if (String.IsNullOrWhiteSpace(suffixPrefixTbox.Text))
            {
                Program.Print("Can't add empty text to filenames!");
            }
            else
            {
                OtherUtils.AddSuffixPrefixDir(suffixPrefixTbox.Text, suffix);
            }
        }