コード例 #1
0
 private String getLineDelimiter() {
   BundleInputContext inputContext = getBundleContext();
   if (inputContext != null) {
     return inputContext.getLineDelimiter();
   }
   return System.getProperty("line.separator"); // $NON-NLS-1$
 }
コード例 #2
0
 private void handleDelete() {
   IStructuredSelection ssel = (IStructuredSelection) fPluginTable.getSelection();
   if (ssel.size() > 0) {
     Object[] objects = ssel.toArray();
     IProductPlugin[] plugins = new IProductPlugin[objects.length];
     System.arraycopy(objects, 0, plugins, 0, objects.length);
     getProduct().removePlugins(plugins);
     updateRemoveButtons(true, true);
   }
 }
コード例 #3
0
 private void updateArgumentPreview(IArgumentsInfo launcherArguments) {
   StringBuffer buffer = new StringBuffer();
   String delim = System.getProperty("line.separator"); // $NON-NLS-1$
   String args =
       launcherArguments.getCompleteProgramArguments(
           TAB_LABELS[fLastTab], TAB_ARCHLABELS[fLastArch[fLastTab]]);
   if (args.length() > 0) {
     buffer.append(PDEUIMessages.ArgumentsSection_program);
     buffer.append(delim);
     buffer.append(args);
     buffer.append(delim);
     buffer.append(delim);
   }
   args =
       launcherArguments.getCompleteVMArguments(
           TAB_LABELS[fLastTab], TAB_ARCHLABELS[fLastArch[fLastTab]]);
   if (args.length() > 0) {
     buffer.append(PDEUIMessages.ArgumentsSection_vm);
     buffer.append(delim);
     buffer.append(args);
   }
   fPreviewArgs.setValue(buffer.toString());
 }