snippetModel.prepareForCreate();
// Disable some buttons and grid while the new snippet is not save
Button addcodeButton = (Button) editWindow.getFellow("addcodeButton");
Button saveButton = (Button) editWindow.getFellow("saveButton");
Button saveandcontinueButton = (Button) editWindow.getFellow("saveandcontinueButton");
Grid snippetCodeGrid = (Grid) editWindow.getFellow("snippetCodeGrid");
addcodeButton.setDisabled(true);
saveButton.setDisabled(true);
saveandcontinueButton.setDisabled(true);
snippetCodeGrid.setVisible(false);
showEditWindow("Create a new snippet");
isnewSnippet = true;
}